2017-02-23 4 views
0

月曜日01:00 - 02:00のイベント数が同じ期間の10%より大きいか小さい場合に警告するElastAlertで警告を設定しようとしています前週の月曜日から。先週のElastAlertでのデータ比較

私たちのデータは、日曜日から月曜日までと比較して、日曜日から時々刻々と異なります。

この種のチェックにはスパイクタイプまたは他のフィルタを使用する方法はありますか?

+0

こんにちは、どこでこれを解決しようとしていますか? – kumar

+0

まだ私は恐れています。あなたが何かを見つけることができれば、報告してください –

答えて

0

私は同じ種類の問題がありました。私はelastAlertをフォークし、新しいルールタイプを追加しました。

フードの下では、別のES呼び出しを行い、データを比較します。それは少し汚れており、元のelastAlertアーキテクチャに適合しません。しかしそれは事をする。 「スパイク」ルールと「メトリック集約」ルールが混在しています。ここで

https://github.com/spodgurskiy/elastalert

私のルール構成の一例です。

# Alert when there is a sudden spike comparing to the historical data 
name: Spike detection 

type: metric_history_aggregation 
index: metrics-* 

# Reference window diff in minutes 
date_diff_ref: 10080 

# Spike detection 
threshold_total: 50 
threshold_cur: 0 
threshold_ref: 0 

spike_height: 1.05 
spike_type: both # <both/up/down> 

# Aggregation 
metric_agg_key: "<field_name>" 
metric_agg_type: sum 
max_threshold: 

# Alert section 
alert: 
- "slack" 
alert_display_timezone: US/Pacific 
alert_text_type: exclude_fields 
alert_subject: "" 
slack_webhook_url: "https://hooks.slack.com/services/..."