Integration Server 10.15 | JMS Client Development Guide | Consuming JMS Messages Concurrently in a Load-Balanced Fashion | Consuming JMS Messages in Order with Multiple Consumers | Consuming JMS Messages in Order Using the webMethods Broker
 
Consuming JMS Messages in Order Using the webMethods Broker
You can configure the webMethods Broker to distribute messages to multiple consumers in the same order in which the webMethods Broker received the messages. To do this, when creating destinations in Designer, set the Order By property to Publisher. When using the Broker interface in My webMethods to create destinations (queue or durable subscriber), set the Shared State property to “publisher”.
When a destination has a shared state order of publisher, the webMethods Broker distributes messages to consumers in a serial fashion. This occurs even if multiple load-balanced consumers share the same destination. For example, suppose that Server1 and Server2 request messages from QueueA on behalf of JMS triggers. The webMethods Broker gives Server1 the first message in the queue. The request from Server2 for a message is blocked until Server1 acknowledges the message. Server2 then receives the next message.
Note:
By default, Integration Server retrieves and caches up to 10 messages per request for a JMS trigger. The watt.server.jms.trigger.maxPreFetchSize server parameter determines the number of messages retrieved for each request. For more information about this parameter, see webMethods Integration Server Administrator’s Guide.