Documentation: Fix watcher script condition using params
Original commit: elastic/x-pack-elasticsearch@fe6d819d64
This commit is contained in:
parent
bccf988e9d
commit
ff725afe01
|
@ -35,7 +35,7 @@ parameter, `result`:
|
|||
--------------------------------------------------
|
||||
"condition" : {
|
||||
"script" : {
|
||||
"source" : "return result",
|
||||
"source" : "return params.result",
|
||||
"lang" : "painless",
|
||||
"params" : {
|
||||
"result" : true
|
||||
|
@ -113,7 +113,7 @@ threshold:
|
|||
},
|
||||
"condition" : {
|
||||
"script" : {
|
||||
"source" : "return ctx.payload.hits.total > threshold",
|
||||
"source" : "return ctx.payload.hits.total > params.threshold",
|
||||
"params" : {
|
||||
"threshold" : 5
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue