While the watcher sending alert, I want more information in alert. I have "mysecond" index. I have set watch like this. The index and type has additional fields like address. In alert, I want them to be available.
In elasticsearch it is equavalent to fields.
I saw scripts and alert for dynamic content. I am looking for available options rather than learning and writing groovy.
First, can you use code blocks for better readability, see this markdown documentation for help.
second, can you be more verbose regarding your use-case? If you want to extract fields from the document being returned, you can use the payload, please see the actions, on how to access parts of the search response. If you mean something else, please take the time and provide a fully fledged example.
Also there is no need to really learn groovy as a language, we just use a very very small of features here, no need to be afraid of that.
Thanks for the response. The context is want to send more info in watcher webhook. At the time of posting, I was not aware that ctx.payload available in watcher alert. Using ctx.payload helped me. I am fine with ctx.payload.
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.