Does anyone know if there\'s a way to check the number of messages in a RabbitMQ queue from a client application?
I\'m using the .NET client library.
my little snippet based on Myydrralls' answer. I think if he had code in his answer I might have noticed it much quicker.
public uint GetMessageCount(string queueName)
{
using (IConnection connection = factory.CreateConnection())
using (IModel channel = connection.CreateModel())
{
return channel.MessageCount(queueName);
}
}