-
Bug
-
Resolution: Unresolved
-
Normal
-
None
-
1.2.0, 1.3.0
-
None
-
Quality / Stability / Reliability
-
False
-
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
The korrel8r can not display the alert from Loki.
$korrel8rcli -k -o json neighbours -u https://127.0.0.1:9443 --query 'alert:alert:
{"alertname":"DevAppLogVolumeIsHigh"}'
{"edges":null,"nodes":null}Step to reproduce:
- Deploy cluster-logging
- Create alert in user namespace
oc create ns $user_namespace
oc label ns $user_namespace openshift.io/cluster-monitoring="true"
oc label ns $user_namespace openshift.io/log-alerting="true"
create alertingrule in ${user_namespace}
cat <<EOF |oc -n ${user_namespace} apply -f -
apiVersion: loki.grafana.com/v1
kind: AlertingRule
metadata:
labels:
openshift.io/log-alerting: "true"
name: dev-workload-alerts
spec:
groups:
- interval: 1m
name: devAppAlert
rules:
- alert: DevAppLogVolumeIsHigh
annotations:
description: My application has high amount of logs.
summary: project "{${user_namespace}" log volume is high.
expr: >
count_over_time({kubernetes_namespace_name="${user_namespace}"}[2m])
> 10
for: 5m
labels:
severity: info
devApp: 'true'
tenantID: application
EOF
- query the alert
port forward korrel8 to local
korrel8rcli -k -o json neighbours -u https://127.0.0.1:9443 --query 'alert:alert: {"alertname":"DevAppLogVolumeIsHigh"}'