Wednesday, February 9, 2011

Synchronously send and consume the JMS message in BPEL

Sychronous JMS provider

When sending out a JMS message sychronously from BPEL - which means that you send out JMS message to a destination and BPEL process will not procede until it get the JMS message
from ReplyTo destination.


Figure 1

Steps to create sychronous JMS provider

  • Define the WSDL with the type "Send and Wait for Reply" which will generate the 2-way WSDL as shown in Figure 1.
  • So before the message is send out several Header properties are to be set. The figure 2 shows one example of configuring the JMS BC for setting up these properties.


Figure 2

Sychronous JMS consumer

When consuming a JMS message sychronously in BPEL, the BPEL instance wil pick up a message from the destination and start to process the message until it sends out a reply message to the destination specified as ReplyTo header property in the coming message. THEN the BPEL instance starts to pick up the next message in the destination.

Steps to create sychronous JMS consumer

  • Define the WSDL with the type "Receive and Reply" which will generate the 2-way WSDL as shown in Figure 1.
  • Set the ReplyTo header property of the message to be consumed by the BPEL.
message.setJMSReplyTo(this.queueDummyEDCBulkLoadReply);

No comments:

Post a Comment