Created
January 28, 2017 05:33
-
-
Save johtani/49911186cd21a69d98ab5572766e0c73 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
POST _reindex | |
{ | |
"source": { | |
"index": "apache_elk_example_org" | |
}, | |
"dest": { | |
"index": "apache_elk_example" | |
}, | |
"script": { | |
"inline": "Random rdm = new Random();ctx._source['@timestamp'] = params.dates[rdm.nextInt(params.dates.length)]+ ctx._source['@timestamp'].substring(10);", | |
"lang": "painless", | |
"params": { | |
"dates": ["2017-01-27", "2017-01-28"] | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment