Tuesday, October 15, 2013

Oracle SOA Transaction in BPel and Mediator

Oracle SOA Transaction in BPel and Mediator:

Oracle SOA Transaction in BPel and Mediator:

BPel:
Transaction in BPel is depends on the idemponent value of invoke activity.
If the idemponent value is set to false then new transaction is created after that invoke. Also dehydrate the invoke idemponent false activity. Point to be noted here is all the resources which are getting used is binded with XA transaction. If resources are binded with XA transaction something like webservice then we need to use compensating transactions



Mediator:
Transaction in mediator uses the existing transaction from the callee if the transaction exist else it will create a new transaction.

Syn Routing
In case of sync routing rules, they will be all executed in the same transaction, and if an error occurs, a rollback will be issued.

Note: in this case even a fault policy that is configured against a mediator fault will NOT trigger.

Explanation for Fault Policy not getting triggered:
In below scenario there are three invoke activities, in syn routing all are under one transaction. If second invoke fails then both invoke 1 and 2 is rolled back.  Concidered fault policy is written to retry when remote fault occurs. If fault policy is triggered then retry will be happening only for Invoke 2 but Invoke 1 is already rolled back hence fault policy is not triggered during synch routing.

Invoke 1

Invoke 2 ---> Exception (RemoteFault)

Invoke 3

 
Asynch Routing:
In case of async routing rules, each rule will be executed in a new transaction, and if errors occur, a rollback will happen, and a fault policy can be configured to react to it.


Refence:
http://www.oracle.com/technetwork/articles/soa/wli-bpel-transactions-088255.html
https://blogs.oracle.com/soabpm/entry/soa_suite_11g_-_transactions_b

No comments:

Post a Comment