Closed reinvantveer closed 6 years ago
We are aware of this. It's not a big problem. We needed to find a very ugly solution for a weird issue in ES: if you delete an item from a non-existing index, this index is created.
@reinvantveer is this an issue besides being ugly?
This is just ugly. And not so much an issue. Related with histograph/api#72.
This is not an issue, and the solution is now to handle the error in the code and not log it if it is due to this problem
ES => 57 indexed, took 10243ms, errors: false Failed creating index { [Error: [index_already_exists_exception] already exists, with: {"index":"verdwenen-dorpen"}] status: '400', message: '[index_already_exists_exception] already exists, with: {"index":"verdwenen-dorpen"}', path: '/verdwenen-dorpen', query: {}, body: '{"settings":{"number_of_shards":5,"number_of_replicas":0,"analysis":{"analyzer":{"lowercase":{"type":"custom","filter":" lowercase","tokenizer":"keyword"}}}},"mappings":{"default":{"properties":{"geometry":{"precision":"1m","tree":"quadtree","type":"geo_shape"},"uri":{"index":"not_analyzed","type":"string"},"id":{"index":"not_analyzed","store":true,"type":"string"},"type":{"index":"not_analyzed","type":"string"},"name":{"fields":{"analyzed":{"index":"analyzed","store":true,"type":"string"},"exact":{"analyzer":"lowercase","store":true,"type":"string"}},"type":"string"},"dataset":{"index":"not_analyzed","type":"string"},"validSince":{"format":"date_optional_time","type":"date"},"validUntil":{"format":"date_optional_time","type":"date"}}}}}', statusCode: 400, response: '{"error":{"root_cause":[{"type":"index_already_exists_exception","reason":"already exists","index":"verdwenen-dorpen"}],"type":"index_already_exists_exception","reason":"already exists","index":"verdwenen-dorpen"},"status":400}', toString: [Function], toJSON: [Function] } '[index_already_exists_exception] already exists, with: {"index":"verdwenen-dorpen"}'