I am trying to write a monitoring solution for ActiveMQ using C#. As part of that i need to monitor number of pending messages in a queue and number of consumers active for that queue. Can you please help me how to get number of consumers for a queue. I am able to count no of pending messages by using this answer
For a management solution, I would use the JMX management API. Using a JVM language you could connect to ActiveMQ JMX that can tell you those metrics. For C# you want to use jolokia, which is a "JMX to HTTP brigde".
Would give you a JSON response with, among other metrics, ConsumerCount, EnqueueCount and DequeueCount.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.