DefaultMessageListenerContainer = polling mechanism = one polling receive() thread per configured listener.
SimpleMessageListenerContainer => push mechanism = only a thread in case messages arrive.
Let's say I have a production environment with 10 queues.
Let's say a message is to be consumed once-and-only-once.
I could configure 1 DMLC with 10 listeners (one per queue).
But that would mean that 10 threads are always in use, even when no message are to be processed.
Is that a correct conclusion ?
If so, doesn't that imply that using DMLC is very inefficient due to the fact so many threads are doing nothing ?
Wouldn't a SMLC approach be better in that respect ?
But then will SMLC work with JTA transaction manager and XA transactions ?
If not, what are my options if I want to use threads efficiently and at the same time I want to use JTA txn manager and XA ?


Reply With Quote
