apache/pulsar

About pulsar CPU usage problem

Open

#14.662 geöffnet am 11. März 2022

Auf GitHub ansehen
 (2 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Java (3.485 Forks)batch import
Stalehelp wantedlifecycle/staletype/bug

Repository-Metriken

Stars
 (13.697 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 3T 10h) (146 gemergte PRs in 30 T)

Beschreibung

Describe the bug The CPU utilization calculated by process_cpu_seconds_total, pulsar_lb_cpu_usage provided by pulsar and container metrics provided by kubernetes are inconsistent and vary greatly, which is the correct one? Why is there a difference?

Expressions for calculation of indicators

# process_cpu_seconds_totall
irate(process_cpu_seconds_total{pod="pulsar-private-broker-0"}[5m])

# pulsar_lb_cpu_usagel
pulsar_lb_cpu_usage{pod="pulsar-private-broker-0"}

# Container Metrics Metrics provided by kubernetes
sum(irate(container_cpu_usage_seconds_total{pod="pulsar-private-broker-0"}[5m])) by (pod) / sum(kube_pod_container_resource_limits_cpu_cores{pod="pulsar-private-broker-0"}) by (pod)

Contributor Guide