elastic/elasticsearch
View on GitHubMissing ID for an update/delete operation causes the entire bulk to fail
Open
#10428 opened on Apr 4, 2015
:Distributed/CRUD>bugTeam:Distributedhelp wanted
Description
If one of the actions from a bulk requires an ID (update/delete) but doesn't have it, the entire bulk fails. For example:
$ cat /tmp/test_bulk
{"index":{}}
{"name":"test doc"}
{"delete":{}}
$ curl -XPOST localhost:9200/test/test/_bulk?pretty --data-binary @/tmp/test_bulk
{
"error" : "ActionRequestValidationException[Validation Failed: 1: id is missing;]",
"status" : 400
}
I would expect the index operation to succeed and the delete/update operation to fail. Or maybe there's a good reason for failing the whole bulk that I don't see?