{ "name": "Kyma Telemetry Status", "type": "monitor", "monitor_type": "query_level_monitor", "enabled": true, "schedule": { "period": { "unit": "MINUTES", "interval": 1 } }, "inputs": [ { "search": { "indices": [ "metrics-otel-v1-*" ], "query": { "size": 0, "query": { "bool": { "filter": [ { "range": { "time": { "from": "{{period_end}}||-10m", "to": "{{period_end}}", "include_lower": true, "include_upper": true, "format": "epoch_millis", "boost": 1 } } }, { "match_phrase": { "name": { "query": "kyma.resource.status.state", "slop": 0, "zero_terms_query": "NONE", "boost": 1 } } } ], "must_not": [ { "match_phrase": { "metric.attributes.state": { "query": "Ready", "slop": 0, "zero_terms_query": "NONE", "boost": 1 } } } ], "adjust_pure_negative": true, "boost": 1 } } } } } ], "triggers": [ { "query_level_trigger": { "name": "Inform about module problem", "severity": "1", "condition": { "script": { "source": "ctx.results[0].hits.total.value > 0", "lang": "painless" } }, "actions": [ { "name": "Inform about module problem", "destination_id": "", "message_template": { "source": "Monitor {{ctx.monitor.name}} just entered alert status. Please investigate the issue.\n - Trigger: {{ctx.trigger.name}}\n - Severity: {{ctx.trigger.severity}}\n - Period start: {{ctx.periodStart}}\n - Period end: {{ctx.periodEnd}}\n - /app/alerting", "lang": "mustache" }, "throttle_enabled": true, "subject_template": { "source": "Module in non-ready state", "lang": "mustache" }, "throttle": { "value": 60, "unit": "MINUTES" } } ] } } ] }