Skip to content

Instantly share code, notes, and snippets.

@quoeamaster
Created December 5, 2019 07:33
Show Gist options
  • Save quoeamaster/976ade7b2e58aee4cf68c162d8c2f9fd to your computer and use it in GitHub Desktop.
Save quoeamaster/976ade7b2e58aee4cf68c162d8c2f9fd to your computer and use it in GitHub Desktop.
POST _ingest/pipeline/_simulate
{
"pipeline": {
"description": "any stage: add back last_update_time by script",
"processors": [
{
"script": {
"lang": "painless",
"source": """
def ts = new Date();
ctx.last_update_time = ts;
"""
}
}
]
},
"docs": [
{
"_source": {
"action": "filling_procurement_form",
"user": "jaime_10234",
"procurement_id": "12_yuy190"
}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment