Wednesday, September 21, 2011

Two scenarios of invoking asychronous service from BPEL

OrderService is one asynchronous service. When invoking it from one BPEL process we can have the different behaviour by using different activities: in one scenario OrderService is invoked and then BPEL process will wait for the callback response from OrderService. If the specified timeout occurs the notification is sent off but BPEL process continues the waiting for the response. However in another scenario after invoking OrderService BPEL will wait for the callback response. If the specified timout occurs BPEL will handle the timeout and will not wait for the callback response any more.

The first scenario can be implemented by using the activity invoke, receive wrapped in the scope with which onAlarm is attached.

The second scenario is implemented using pick activity. One branch of pick is onMessage to wait for the callback and another branch is onAlarm.

No comments:

Post a Comment