Message Delivery to Selector-based Consumers Pauses If Selector Leaves Messages On The Queue.
Issue
You have one or more consumers that are all subscribed to a queue and all are using a particular selector to consume messages from a queue; lets assume the selector is foo=‘bar’.
You then assign a set of producers to write messages to that particular queue, where the set comprises producers that write messages with and without a matching field; i.e., some messages have a foo:bar key-value field or header and others do not. So the queue ends up with a mix of messages that will and will not match the consumers’ selector of foo=‘bar’.
What you notice is that over time (amount of time depends on the message load and mix of messages) the consumers stop consuming messages even though the queue has messages that match the selector. You also notice that the percent memory usage for the queue is well below the high water mark and the cache or cursor is still enabled and was never previously disabled. So all the messages are in the in-memory cache and still the consumers are not being dispatched any matching messages.
Environment
Fuse A-MQ 6.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
