Business processes in WebLogic Integration are transactional in nature. Every step of a process is executed within the context of a JTA transaction. A transaction ensures that one or more operations execute as an atomic unit of work. If one of the operations within a transaction fails, then all of them are rolled-back so that the application is returned to its prior state. Depending on whether you design your business process logic such that your process is stateful or stateless (see, Building Stateless and Stateful Business Processes), there may be one or more transactions within the context of a given business process.
When you are building a business process, implicit transaction boundaries are formed based on where in the process you place blocking elements. The transaction boundaries within a business process change as you add process nodes to the business process. You can also create explicit transaction boundaries by selecting contiguous nodes and declaring them to be in a transaction separate from those created implicitly by the application. Resources accessed by a business process may also be part of the transaction, depending on the nature of the resource and the control that provides the access.
Implicit transactions are implicit both because their behavior is automatically determined (or implied) by your business process logic and because they are not visible in your process diagram. In the section, An Implicit Transaction Boundary Example, the implicit transaction boundaries in the diagrams are added for illustration; implicit transaction boundaries are not visible in the WebLogic Workshop graphical design environment. Explicit transactions, on the other hand, are explicit because they are defined by you and they are visible in the business process diagram in WebLogic Workshop.
This following sections deal specifically with transactions in the context of WebLogic Integration and business processes:
Note: To learn about how WebLogic Workshop transactions work, see Default Transactional Behavior in WebLogic Workshop.
Recall that implicit transaction boundaries are formed based on where in the process you place blocking elements and that these boundaries change as you add process nodes to the business process. Additionally, a business process is stateless by default, and blocking elements that change transaction boundaries can change the process to stateful (see, Building Stateless and Stateful Business Processes). For more information about The following rules apply to transaction boundaries when you are building a business process:
Note: By default, the beginning and the end of a parallel group node mark the boundaries of new transactions. However, you can specify that the active transaction is continued when entering and exiting a parallel block. To use this functionality, in Design View, select the for a parallel node in your business process, then, in the Property Editor, change the continue transaction property to true.
The following example illustrates the rules listed in the Implicit Transaction Boundary Rules section. In each of the figures in this section, the transaction boundaries are added to illustrate where they are implied in WebLogic Integration business processes.
Since the business process now contains two transactions, the Start node icon changes to indicate that the business has changed from Stateless
to Stateful
. For more information about Stateless and Stateful business processes, see Building Stateless and Stateful Business Processes.
This concludes the implicit boundaries example, you can also create transactions by adding explicit transaction boundaries to your business process. For information about how to do this, see Explicit Transaction Boundaries.
Recall that you define explicit transaction boundaries and that they are visible in the business process diagram in WebLogic Workshop.You can create explicit transaction boundaries in your business process by selecting contiguous nodes and declaring them to be within their own transaction. The following rules apply for explicit transaction boundaries:
If you violate any of these rules when you create your business process, the application displays the transaction boundaries, but the offending nodes are marked with a
. If you place your cursor over this icon,WebLogic Workshop will display a message about the violation.
To Create an Explicit Transaction—Alternative 1
Explicit transaction boundaries are drawn around the nodes you selected.
You can rename your transaction block by right-clicking Transaction and selecting Rename from the drop-down menu.
To Create an Explicit Transaction—Alternative 2
Transaction boundaries are created in the business process.
After you create an explicit transaction, you can set the properties for the transaction in the Property Editor.
To Set the Transaction Properties
The related properties are displayed in the Property Editor. If the Property Editor is not visible in WebLogic Workshop, choose View —> Property Editor from the menu bar.
To learn about exception handling in business processes, see Handling Exceptions. How exceptions are handled in transaction blocks is described in Handling Exceptions in Transaction Blocks.
Implicit Transactions in WebLogic Workshop
Default Transactional Behavior in WebLogic Workshop
Building Stateless and Stateful Business Processes
Configuring and Managing Transactions at http://download.oracle.com/docs/cd/E13222_01/wls/docs81/jta/admtrx.html
![]() |
![]() |