Skip to content

Commit

Permalink
Documentation: Fix etcdHighNumberOfFailedGRPCRequests rules return Na…
Browse files Browse the repository at this point in the history
…N value
  • Loading branch information
guoruyi1 committed Apr 12, 2019
1 parent c7c6894 commit 333c8ba
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions Documentation/op-guide/etcd3_alert.rules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ groups:
message: 'etcd cluster "{{ $labels.job }}": {{ $value }}% of requests for {{
$labels.grpc_method }} failed on etcd instance {{ $labels.instance }}.'
expr: |
100 * sum(rate(grpc_server_handled_total{job=~".*etcd.*", grpc_code!="OK"}[5m])) BY (job, instance, grpc_service, grpc_method)
/
sum(rate(grpc_server_handled_total{job=~".*etcd.*"}[5m])) BY (job, instance, grpc_service, grpc_method)
> 1
sum(rate(grpc_server_handled_total{job=~".*etcd.*", grpc_code!="OK"}[5m])) BY (job, instance, grpc_service, grpc_method)
> bool
0.01 * sum(rate(grpc_server_handled_total{job=~".*etcd.*"}[5m])) BY (job, instance, grpc_service, grpc_method)
> 0
for: 10m
labels:
severity: warning
Expand All @@ -46,10 +46,10 @@ groups:
message: 'etcd cluster "{{ $labels.job }}": {{ $value }}% of requests for {{
$labels.grpc_method }} failed on etcd instance {{ $labels.instance }}.'
expr: |
100 * sum(rate(grpc_server_handled_total{job=~".*etcd.*", grpc_code!="OK"}[5m])) BY (job, instance, grpc_service, grpc_method)
/
sum(rate(grpc_server_handled_total{job=~".*etcd.*"}[5m])) BY (job, instance, grpc_service, grpc_method)
> 5
sum(rate(grpc_server_handled_total{job=~".*etcd.*", grpc_code!="OK"}[5m])) BY (job, instance, grpc_service, grpc_method)
> bool
0.05 * sum(rate(grpc_server_handled_total{job=~".*etcd.*"}[5m])) BY (job, instance, grpc_service, grpc_method)
> 0
for: 5m
labels:
severity: critical
Expand Down

0 comments on commit 333c8ba

Please sign in to comment.