I am trying to write a multi-threaded implementation for processing JMS messages from a queue.
I tried the classes DefaultMessageListenerContainer and SimpleMessageListenerContainer.
The problem is that it seems that only one instance of the MessageListener class gets the instance, no matter how I configure it. This forces me to unnecessarily write idle or thread-safe MessageListener implementations, since I have a ListenerContainer configured to use multiple threads (concurrentConsumers = 8).
Is there an obvious solution for this that I am missing?
source
share