Elasticsearch Query & Update Script (node.js based)