I have been using ctx.execution_time.getMillis() in painless script for my watcher and it has been working until 6.5.0. Here is the error from watcher execution:
"type": "script_exception",
"reason": "runtime error",
"script_stack": [
"fromTime = ctx.execution_time.getMillis() - toMillis(ctx.payload.monitor.period);\n ",
" ^---- HERE"
],
"lang": "painless",
"caused_by": {
"type": "illegal_argument_exception",
"reason": "dynamic method [org.joda.time.DateTime, getMillis/0] not found"
}
What is the new way to get the milliseconds from the ctx.execution_time if this is not a bug?