Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8990221
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T22:27:16+00:00 2026-06-15T22:27:16+00:00

I have a JMS listener pool: <jms:listener-container connection-factory=jmsConnectionFactory acknowledge=client concurrency=10> <jms:listener destination=foo1 ref=ref1/> <jms:listener

  • 0

I have a JMS listener pool:

<jms:listener-container connection-factory="jmsConnectionFactory" 
 acknowledge="client" concurrency="10">
    <jms:listener destination="foo1" ref="ref1"/>
    <jms:listener destination="foo2" ref="ref2"/>
    <jms:listener destination="foo3" ref="ref3"/>
    <jms:listener destination="foo4" ref="ref4"/>  // etc...
</jms:listener-container>

I’m looking for a way to ensure that some of my message types don’t starve or block out all the others. Example: I would prefer to have at least M but no more than N percent of my pool be dedicated to processing foo1 messages, even though such processing may erratically stall.

Presently, if I let this happen, then all 10 threads in my pool will end up dedicated to foo1 messages. foo{2-4} messages will have to wait. I can prevent such starvation by enforcing timeouts on my foo1 listener, but then I fail my throughput goals.

Is there some easy configuration-based way of achieving this? Can I have two JMS listener pools running at once?

Or is my safest bet just to set up two entirely different server fleets, one dedicated to foo1 messages, the other to foo2-4?

Ideally, I would like to do something like the following. But “concurrency” isn’t an attribute of jms:listener, just jms:listener-container:

<jms:listener-container connection-factory="jmsConnectionFactory" 
 acknowledge="client" concurrency="25">
    <jms:listener destination="foo1" ref="ref1" concurrency="10" /> // ensure higher throughput
    <jms:listener destination="foo2" ref="ref2" concurrency="5" />  // don't let foo1 starve me...
    <jms:listener destination="foo3" ref="ref3" concurrency="5" />  // don't let foo1 starve me...
    <jms:listener destination="foo4" ref="ref4" concurrency="5" />  // etc...
</jms:listener-container>

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T22:27:18+00:00Added an answer on June 15, 2026 at 10:27 pm

    Understand that the namespace configuration is just a convenience to simplify configuration. Each <listener/> element gets its own listener container and “inherits” the attributes from the <listener-container/> element.

    So, in your first example, the concurrency=”10″ is not shared across all the listeners; each <listener/> gets a concurrency of 10.

    You can achieve your second example by declaring two <listener-container/> elements, one with concurrency 10 and one with 5. Then declare each listener in the appropriate container element.

    Hope that helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a server application receiving messages from a JMS queue. And client applications
i have various strings that look like that: $(gateway.jms.jndi.ic.url,0,tibjmsnaming, tcp)/topic/$(gateway.destination.prefix)$(gateway.StatusTopicName),$(gateway.jms.jndi.ic.username),$(gateway.jms.jndi.ic.password),abinding,tBinding i'm trying to figure
I am new JMS arena, I have created multiple message listeners but one listener
I use Spring-configured jms template with tibco jms library. I get jms connection factory
I have a JMS client that can ssh to remote systems upon receiving a
I currently have about 3 messages from a JMS client sending to a MDB
I have a Spring JMS listener that receives a BytesMessage/JMSBytesMessage. I want to convert
I have a JMS listener app, and the class QueueReceive implements MessageListener.the main function
I have a DefaultMessageListenerContainer setup with the following configuration: threadServiceListenerContainer(org.springframework.jms.listener.DefaultMessageListenerContainer) { maxConcurrentConsumers = 10
If I have an AQ set up, but my listener (Mule JMS endpoint) is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.