With Exception handling patterns chapter , we have covered patterns related to exception handling in Oracle BPM. Here let’s try to understand different levels of timeout and where to set the properties for them and equation to follow.
- Global java Transaction Timeout (JTA) :
- Navigation: WLS Console –> Domain –> Configuration –> JTA
- Description: You cannot catch fault if the timeout is occurring at JTA level. Neither a CATCH activity nor the fault policy will help in this scenario.
- Effect: Instance will get rollback to last dehydration point.
- EJB Timeout (JTA) :
- Navigation: WLS Console –> Deployments –> Control –> Expand SOA-INFRA –> Expand EJB node. Increase the “Transaction Timeout” (value in seconds) in the “Configuration” tab for the following EJB’s by clicking on them.
- Description: Many BPM engine EJB’s exist in “soa-infra” Enterprise application which process the message during runtime, each EJB has its own timeout parameter which need to configure and should be in relation with JTA and Resource timeout.
- Effect: You cannot catch fault if the timeout is occurring at JTA level. Neither a CATCH activity nor the fault policy will help in this scenario.Instance will get rollback to last dehydration point.
- Resource Timeout :
- Navigation: In composite.xml OR WLS EM –> Click on Project –> Service and References –> Click on the component. Example you are referencing a web service then you can set HTTP read timeout and HTTP Connection timeout from EM or you can set them in composite.xml at design time as properties in the reference section of the respective component. Same can be done for another JCA adapter like database adapter. You can set query timeout from EM console for the DB adapter. You can use catch or fault policy to handle such exceptions.
Equation to follow –
If the Request pattern is as follows –
Consumer –> DMZ/Firewall/Load balancer –> SOA Managed Server –> Provider System
Example – A portal application invokes a composite service which is referencing a database adapter to call a stored procedure.
Equation Can be –
Consumer System Timeout > DMZ System/Firewall/Load balancer timeout > JTA Timeout > EJB Timeout > Resource Timeout > Provider (Database)
Base equation to follow among the components discussed is –
JTA Timeout > EJB Timeout > Resource Timeout