I am trying to create a loop where all the arrays are searched to find any have more than one value for "doc_count". Once the loop finishes, and all the fields are identified, I wish to put these in a separate array to use this for my action.
When I execute the condition, I get a compile error. Can you please help me?
mustache style index usage buckets.0.doc_count, that must be buckets[0].doc_count.
new_list is used as a map but initialize it as a list.
missing semicolon at the last line of the for loop.
debugging tip: When using kibana console, instead of using "script" : "your...script" use
"script": """
def foo...
return ...;
"""
those triple ticks allow you to write scripts in multiple lines, make them more readable and the console is doing all the escaping and using single ticks when sending to ES.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.