I am an activeMQ newbie. Is it possible to add something to the activeMQ xml configuration to force a queue to stop accepting messages when (for example) 100 messages are already in a specific queue?
A:
ActiveMQ expose the queue size with JMX, so i guess you can use that information to limit the queue size. see: Queue size thread
saad
2010-08-30 10:38:59
A:
Take a look at Producer Flow Control http://activemq.apache.org/producer-flow-control.html
It limits your queue on the amount of memory the queue takes
Dejan Bosanac
2010-08-30 13:28:15
A:
Depending on your requirements, you may want to consider configuring a pending message limit strategy or a message eviction policy:
http://activemq.apache.org/slow-consumer-handling.html
These two options are mainly for use in a slow consumer situation to work with the consumer's prefetch buffer. But I'm suggesting them to you because I don't understand the full context of your question or know your requirements.
Bruce
bsnyder
2010-08-30 15:52:29