elastalert

Elastalert simplified multiple rules in one file

浪子不回头ぞ 提交于 2020-08-07 07:54:29
问题 I'm writing Elastalart rules for heartbeat i.e if service or machine are/is down, I should get notified. Right now I can create one rule for service per one file like below. name: My Alert type: frequency index: heartbeat-* num_events: 5 timeframe: minutes: 2 filter: - query: query_string: query: "url.domain: MY_LOCALHOST01.local AND monitor.status: down" alert: - "email" email: - "user@example.in" Is there any way, can I specify multiple rules??... I can specify multiple filter like below ..

Elastalert simplified multiple rules in one file

雨燕双飞 提交于 2020-08-07 07:54:05
问题 I'm writing Elastalart rules for heartbeat i.e if service or machine are/is down, I should get notified. Right now I can create one rule for service per one file like below. name: My Alert type: frequency index: heartbeat-* num_events: 5 timeframe: minutes: 2 filter: - query: query_string: query: "url.domain: MY_LOCALHOST01.local AND monitor.status: down" alert: - "email" email: - "user@example.in" Is there any way, can I specify multiple rules??... I can specify multiple filter like below ..

Elastalert simplified multiple rules in one file

跟風遠走 提交于 2020-08-07 07:54:05
问题 I'm writing Elastalart rules for heartbeat i.e if service or machine are/is down, I should get notified. Right now I can create one rule for service per one file like below. name: My Alert type: frequency index: heartbeat-* num_events: 5 timeframe: minutes: 2 filter: - query: query_string: query: "url.domain: MY_LOCALHOST01.local AND monitor.status: down" alert: - "email" email: - "user@example.in" Is there any way, can I specify multiple rules??... I can specify multiple filter like below ..

query malformed, no start_object after query name

老子叫甜甜 提交于 2020-05-25 06:06:15
问题 I am running this query against AWS Elasticsearch 5.1 and getting a malformed query error. Here is the body of the request. I am basically just checking if the field exists during the time range. { "query": { "bool": { "filter": { "bool": { "must": [ { "range": { "@timestamp": { "gt": "2017-03-21T15:37:08.595919Z", "lte": "2017-04-21T15:52:08.595919Z" } } }, { "query": [ { "query_string": { "query": "_exists_: $event.supplier" } } ] } ] } } } }, "sort": [ { "@timestamp": { "order": "asc" } }

query malformed, no start_object after query name

浪尽此生 提交于 2020-05-25 06:03:06
问题 I am running this query against AWS Elasticsearch 5.1 and getting a malformed query error. Here is the body of the request. I am basically just checking if the field exists during the time range. { "query": { "bool": { "filter": { "bool": { "must": [ { "range": { "@timestamp": { "gt": "2017-03-21T15:37:08.595919Z", "lte": "2017-04-21T15:52:08.595919Z" } } }, { "query": [ { "query_string": { "query": "_exists_: $event.supplier" } } ] } ] } } } }, "sort": [ { "@timestamp": { "order": "asc" } }

searching a specific field in elasticsearch through Spring data elasticsearch

自古美人都是妖i 提交于 2019-12-13 07:08:08
问题 I'm using Spring data Elasticsearch to parse data in ELasticseach . I have already there an indexed element ( elastalert ) witch contains the alert_sent property. So what i want to do is returning all alerts that were sent to the admin. I tried defining a method in the Repository List<Alert> findByAlert_sentTrue() but it seems that the underscore is a problem (as mentioned in the documentation http://docs.spring.io/spring-data/elasticsearch/docs/current/reference/html/#repositories.query