• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

Reading JMS message with highest priority

 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi ,
I am using weblogic 9.2 MP3.
I am sending message(xml) to JMS queue with different priority. I want the highest priority msg to be picked first by consumer.

What I am doing -
1. Currently No consumer is listening ,so that all the message get stuck in JMS queue
2. Then I am posting xmls in JMS queue with default priority(4) first
3. Then posting few xml with Priority 9.

Now I am reading the JMS queue using java client but I am NOT getting the priority 9 message first .
Rather I am getting the message in FIFO order.

 
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Anish,

AFAIK, The priority is not guaranteed.
A JMS provider tries to deliver higher-priority messages before lower-priority ones but does not have to deliver messages in exact order of priority

All the best
 
Anish Kuti
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Many Thanks Rajesh.
Business wants the high priority message to read first . Is there any way we can ensure the top priority msg read first .
 
Rajesh So
Ranch Hand
Posts: 149
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Anish,
JMS Specification does not have such a facility. But you can check if the JMS Provider you are using have such a functionality. What is the JMS Provider you are using? If you are using the Weblogic embedded MQ Provider, I doubt if they have. You can try with other providers like Active MQ, Websphere MQ, Tibco or any other non-opensource/commercial production grade providers.
Regards,
Raj
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic