[Questions] How to measure whether a queue is in a high or low pressure state #13262
-
Community Support Policy
RabbitMQ version used4.0.5 Erlang version used27.2.x Operating system (distribution) usedlinux How is RabbitMQ deployed?Community Docker image rabbitmq-diagnostics status outputNone Logs from node 1 (with sensitive values edited out)None Logs from node 2 (if applicable, with sensitive values edited out)No response Logs from node 3 (if applicable, with sensitive values edited out)No response rabbitmq.confI'm not sure about the cluster configuration Steps to deploy RabbitMQ clusterMy question doesn't require me to provide this information Steps to reproduce the behavior in questionNone advanced.configNo response Application codeNo response Kubernetes deployment fileNo response What problem are you trying to solve?How does rabbitmq calculate the consumption rate of a queue, and what metrics should I base my calculations on if I want to measure how stressed a queue in my cluster is? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
By incrementing certain counters when a I don't know how you define "queue stress". The metrics offered by RabbitMQ's Prometheus scraping endpoint and HTTP API are pretty standard for a messaging and streaming system. With a large number of queues you cannot practically rely on per-queue metrics, only on aggregated ones. There's also a consumer utilization which was renamed but is still as relevant for detecting slow consumers, an insufficient number of them or a low prefetch value used by consumers. There's no shortage of other metrics, including from the runtime, infrastructure and so on. Finally, if you don't know what a node, specific queue or the cluster with N clients can demonstrate as a baseline, you cannot really reason about the level of "stress". Use PerfTest, Stream PerfTests for that. |
Beta Was this translation helpful? Give feedback.
Then see what the available metrics are (in Prometheus but also from
GET /api/queues/{vhost}/{name}
).DO NOT use
GET /api/queues
to fetch one metric of one queue, there are 70 or so metrics per queue rendered and it would be extremely wasteful.