RabbitMQ queues remain in a "running" state even when there are no consumers connected #13439
-
Community Support Policy
RabbitMQ version used4.0.3 How is RabbitMQ deployed?Debian package Steps to reproduce the behavior in questionI have upgraded rabbitmq to version 4.0.5 in ubuntu 22.04 after that in all the queues, state are showing running even if consumers count is zero |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 14 replies
-
@Sameer-Italiya they are "running" because they emit stats and that counts for recent activity. The stats are collected every 5 seconds by default but you can increase this interval (15s-30s sounds reasonable to me). That's also the default management UI update frequency. |
Beta Was this translation helpful? Give feedback.
-
@michaelklishin This is the by default feature the came up with RabbitMQ version 4? If Yes then can we have any release note or documentation where these thing mention like consumers are always in running state in queue unless there is some issue |
Beta Was this translation helpful? Give feedback.
-
If queue is showing idle which means there is no messages that can be produce and consume and from that it assumes no activity is there and if the queue is not in idle state that means it's running state then there should some message produce and consume activity is running. Now in my case if queue state will always in running state then we will never predict that in a queue message activity is running or its idle |
Beta Was this translation helpful? Give feedback.
-
If queue is hibernate then in version 4 also state should be idle but it's in running state only all the time |
Beta Was this translation helpful? Give feedback.
-
This is going in circles. If @mkuratczyk wants to take a closer look, I have no objections, otherwise this is just a waste of everyone's time. The entire metric arguably should be removed and replaced with another one that says whether the queue has an elected leader (for QQs and streams). That's the biggest benefit of this metric, which with default settings will be reported as running, if anything, because of its periodic stats emission. Using this state for monitoring has never been a good idea except for spotting any queues without an elected leader. For which we should soon enough have a dedicated health check. |
Beta Was this translation helpful? Give feedback.
@Sameer-Italiya they are "running" because they emit stats and that counts for recent activity. The stats are collected every 5 seconds by default but you can increase this interval (15s-30s sounds reasonable to me).
That's also the default management UI update frequency.