Lets say I have 1000 users, each user has 50 documents(each document embeds user object having name and email), I need to update name and email for a set of users.
I would like to use Bulk Api, but it seems like bulk API only supports "_id" as the parameter. I would like to make a query instead
For example: I would like to do,
POST _bulk
{ "update" : {"query" : {"terms": {"userId": "25"}}, "_type" : "comments", "_index" : "comments"} }
{ "doc" : {"user.name" : "new name"} }
instead of
POST _bulk
{ "update" : {"_id" : "1", "_type" : "comments", "_index" : "comments"} }
{ "doc" : {"user.name" : "new name"} }