Hello,
I wonder wat is the best way to update a document. I want to add a value to an array and also set some meta data in one request.
I have first an update statement like this:
test/_update/AaCnJ3IBeJO1gLa1SX7H
{
"script" : {
"source": "ctx._source.tags.add(params.att)",
"lang": "painless",
"params" : {
"att" : {
"data": "seven"
}
}
}
}
and then I post like:
test/_update/AaCnJ3IBeJO1gLa1SX7H
{
"doc" : {
"name": "Walter"
}
}