Skip to content

Commit c0f7044

Browse files
ES Version downgrade
1 parent fea8652 commit c0f7044

File tree

6 files changed

+114
-88
lines changed

6 files changed

+114
-88
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,9 @@ Config for tests are at `config/test.js`, it overrides some default config.
6060
- Optionally, use another terminal, go to same directory, start a consumer to view the messages:
6161
`bin/kafka-console-consumer.sh --bootstrap-server localhost:9092 --topic project.notification.create --from-beginning`
6262
- If the kafka don't allow to input long message you can use this script to write message from file:
63-
`path_to_kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic project.notification.create < our_project_root_directory/test/test_topic/project/project.notification.create.json`
63+
`path_to_kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic project.notification.create < our_project_root_directory/test/data/project/project.notification.create.json`
6464
- Writing/reading messages to/from other topics are similar. All example for messages are in:
65-
`our_project_root_directory/test/test_topic`
65+
`our_project_root_directory/test/data`
6666

6767
## Local Elasticsearch setup
6868

@@ -125,7 +125,7 @@ npm run test:cov
125125
- Call our project root directory : `our_project_root_directory`
126126
- Start kafka server, start elasticsearch, initialize Elasticsearch, start processor app
127127
- Send message:
128-
`path_to_kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic project.notification.create < our_project_root_directory/test/test_topic/project/project.notification.create.json`
128+
`path_to_kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic project.notification.create < our_project_root_directory/test/data/project/project.notification.create.json`
129129
- run command `npm run view-data projects 1` to view the created data, you will see the data are properly created:
130130

131131
```bash
@@ -188,7 +188,7 @@ info: {
188188
- Then in the app console, you will see error messages
189189

190190
- Sent message to update data:
191-
`path_to_kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic project.notification.update < our_project_root_directory/test/test_topic/project/project.notification.update.json`
191+
`path_to_kafka/bin/kafka-console-producer.sh --broker-list localhost:9092 --topic project.notification.update < our_project_root_directory/test/data/project/project.notification.update.json`
192192
- Run command `npm run view-data projects 1` to view the updated data, you will see the data are properly updated:
193193

194194
```bash

config/default.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ module.exports = {
2424
ES_PROJECT_INDEX: process.env.ES_PROJECT_INDEX || 'projects',
2525
ES_TIMELINE_INDEX: process.env.ES_TIMELINE_INDEX || 'timelines',
2626
ES_METADATA_INDEX: process.env.ES_METADATA_INDEX || 'metadata',
27-
ES_TYPE: process.env.ES_TYPE || '_doc', // ES 6.x accepts only 1 Type per index and it's mandatory to define it
27+
ES_TYPE: process.env.ES_TYPE || 'doc', // ES 6.x accepts only 1 Type per index and it's mandatory to define it
2828
ES_METADATA_DEFAULT_ID: process.env.ES_METADATA_DEFAULT_ID || 1 // use for setting default id of metadata
2929
}
3030
}

docker-es/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
version: "2"
22
services:
33
esearch:
4-
image: "docker.elastic.co/elasticsearch/elasticsearch:6.7.2"
4+
image: "elasticsearch:2.3"
55
ports:
66
- "9200:9200"

0 commit comments

Comments
 (0)