...
No Format |
---|
{ "script": { "source": "def set=new LinkedHashSet(ctx._source.instances);set.addAll(params.ins);params.del.forEach(set::remove);ctx._source.instances=set", "lang": "painless", "params": { "ins": [ "instanceId#1|type#1", "instanceId#2|type#1", "instanceId#3|type#1" ], "del": [ "instanceId#4|type#1"] } }, "upsert": { "id": "abshc", "name": "Antoniou, Grigoris", "contributorTypeId": "type#1", "instances": [ "instanceId#1|type#1", "instanceId#2|type#1", "instanceId#3|type#1" ] } } |
...