Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-16858

Enhance SjmsPollingConsumer to take messageSelector option into consideration

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 3.12.0
    • camel-sjms
    • None
    • Unknown

    Description

      If you do something like:

      consumerTemplate.receiveBody("sjms:foo.queue?messageSelector=foo='bar'", 5000L, String.class)

      The selector is never used because the logic in SjmsTemplate.receive uses the single argument Session.createConsumer(destination) implementation.

      It should be possible to pass along the selector, and if not empty, do Session.createConsumer(destination, selector).

      The existing unit test for this is flawed, so I guess this has gone unnoticed for some time.

      Attachments

        Issue Links

          Activity

            People

              jamesnetherton James Netherton
              jamesnetherton James Netherton
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: