Hi,
I am trying to execute Watchers which pulls in certain types directly and perform actions it. When I use types to specify the type to read like in the example below, it doesn't work, but does work when I remove types, but I do not want to search a whole lot of data unnecessarily. The other work around I did was to match the type in the inner query. Is it different how this works in ECE or am I missing something here?
This doesn't work -
{
"watch" :{
"trigger": {
"schedule": {
"interval": "1m"
}
},
"input": {
"search": {
"request": {
"indices": [
".my-test-*"
],
"types":["node_stats"],
"body": {
"size" : 0,
This is the workaround I tried for cluster state since types was not working
{
"trigger" : {
"schedule" : { "interval" : "1h" }
},
"input": {
"search": {
"request": {
"indices": ".my-test-*",
"body": {
"query": {
"match": {
"type": "cluster_stats"
}
},
"_source": [
"cluster_state"
],
"sort": [
{
"timestamp": {
"order": "desc"
}
}
],
"size": 1
}
}
}
},