Forum Discussion

schnizlein's avatar
schnizlein
Contributor
16 years ago

Selective Dequeuing for JMS messages

Would it be possible to have JMS requests look for messages with a certain attribute (generally JMSCorrelationID), and not just grab the 'first available'?

If this were possible, we would be able to run an entire test suite in parallel instead of in sequence, which runs the risk (almost guaranteed given enough test cases) of mis-matching messages between test cases.
  • Hi,

    yes you can dequeue selectively with Message Selector in JMS Header inspector.
    Something like JMSCorrelationID = 'mycorrelationid'

    So you will always try to fetch first message from queue but dequeue it only if message selector is satisfied.

    BTW here is the thread with similar issue http://www.eviware.com/forums/http://ww ... 499#p11499

    Hope this helps
    Nebojsa
    eviware.com