-
Notifications
You must be signed in to change notification settings - Fork 25.8k
Updates in bulk api always update shards. #19267
Copy link
Copy link
Closed
Labels
:Distributed/CRUDA catch all label for issues around indexing, updating and getting a doc by id. Not search.A catch all label for issues around indexing, updating and getting a doc by id. Not search.>buggood first issuelow hanging fruitlow hanging fruithelp wantedadoptmeadoptme
Description
Elasticsearch version: 2.3.3
JVM version: 1.8.0_45
OS version: OS X 10.11.5
Description of the problem including expected versus actual behavior:
Bulk api with updates respond _shards.successful > 0 even if new _source not different from the old _source.
Steps to reproduce:
nano request
{ "update" : { "_index" : "test", "_type" : "test", "_id" : "1" } }
{ "doc" : {"data" : "some_data"}, "doc_as_upsert" : true }
# returning _shards.successful = 1
curl -XPOST 'localhost:9200/_bulk' --data-binary "@requests";
# sending request again. This should return _shards.successful = 0 but instead returns _shards.successful = 1
curl -XPOST 'localhost:9200/_bulk' --data-binary "@requests";
Here is example with _update api
# returns _shards.successful = 1
curl -XPOST localhost:9200/test/test/1/_update?pretty -d '{ "doc" : {"data" : "some_data"}, "doc_as_upsert" : true }'
# sending request again. Returns _shards.successful = 0
curl -XPOST localhost:9200/test/test/1/_update?pretty -d '{ "doc" : {"data" : "some_data"}, "doc_as_upsert" : true }'
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
:Distributed/CRUDA catch all label for issues around indexing, updating and getting a doc by id. Not search.A catch all label for issues around indexing, updating and getting a doc by id. Not search.>buggood first issuelow hanging fruitlow hanging fruithelp wantedadoptmeadoptme
Type
Fields
Give feedbackNo fields configured for issues without a type.