Generate BPEL for Oracle workflow engine
BPEL stand for Business Process Execution Language, which is used to describe business process as well as executing the process. This topic is going to introduce the major steps of generating BPEL for Oracle workflow engine.
Drawing BPEL Business Process Diagram
As the name implies, BPEL Business Process Diagram is a Business Process Diagram for BPEL (Business Process Execution Language). It is used to model business process and make it executable.
Creating Participant for Pool
According to the specification of BPEL, each BEPL is described by WSDL. Within BPEL Business Process Diagram, there a something similar Participant of Pool. The below steps demonstrate how to create Participant for Pool by using template.
Open or create Business Process Diagram.
Open Specification of Pool.
Create Participant using template.
Click OK several times to apply and close all dialogs.
| Create option | Creation result |
| Create Participant... | Empty Participant |
| Create asynchronous Participant... | Participant of asynchronous template |
| Create synchronous Participant... | Participant of synchronous template |
Asynchronous Participant
When using asynchronous Participant, the BPEL process will become asynchronous at runtime. As implied by the name, interaction of asynchronous process may not reply immediately. Therefore, another operation should be defined for the callback purpose. In our asynchronous template, two sets of partnerLinkType, portType and operation are included, which to be used for caller and callback.
Synchronous Participant
Opposite to asynchronous Participant, synchronous Participant will cause BPEL process become synchronous at runtime. Any interaction of synchronous Participant must reply immediately. Therefore, only one operation is required and the synchronous template is including only one set of partnerLinkType, portType and operation.
Creating and setting Partner Link
Partner Link is a reference of Web Service used within BPEL. In BPEL Business Process Diagram, Pool is used to define Partner Link.
Open Specification of Pool.
Normally, Pool with Partner Link will be set as black box.
Create Partner Link.
Since Partner Link is separated from Pool, name of Partner Link should be maintained manually.
Participant of Partner Link is used to describe which Web Service it refers to.
Partner Link Type of Partner Link represents the interaction of BPEL and Web Service.
My Role and Partner Role is used for identifying responsibility of interaction. In synchronous process, only one role is required because it is a single direction invocation. In asynchronous process, two roles are required which describe caller role and callback role.
| Role | Description |
| My Role | The role of current business process. |
| Partner Role | The role of opposite side such as client application or Web Service. |
Setting BPEL properties
For executing the business process, some related properties are required to set. Basic properties are described in the example below.
Simple Example
In the example, the Business Process will start by receiving a message. Then it will make some modification to the message. Finally, the modified message will return back.
Draw Business Process.
Start by receive a message.
Open Specification of Task.
Check Instantiate if message will create a process instance. Since process will start when message is received, Instantiate should be checked.
Open Specification of Task Type.
Select Partner Link of receiving message. Since message is from other to current process, the Partner Link should be “Client” which is the Web Service interface of current process.
Select Operation to be invoked by other.
Select the corresponding Varaible. Since the Variable does not exist, create one for it.
Select the corresponding Message. Select Process1_RequestMessage since the Operation required it as input message.
Click OK several times to apply and close all dialog boxes.
Modify the received message.
Open Specification of Task.
Create Assignment.
Create From.
Create To.
Select Varaible to be copied from.
Select Part of Variable to be copied from.
Input Query of the value to be copied from.
Create To Variable. Create a Variable for storing modified message and return back.
Select the corresponding Message. Select Process1_ResponseMessage since the Operation for return required it as input message.
Select Part of Variable to be copied to.
Input Query of the value to be copied to.
Click OK several times to apply and close all dialog boxes.
Return modified message back.
Open Specification of Task.
Open Specification of Task Type.
Check Reply if process is synchronous. Since process is asynchronous, it should not be checked.
Select Partner Link of return message.
Select Operation to be used for return.
Select the corresponding Varaible.
Click OK several times to apply and close all dialog boxes.
Properties Reference
The tables below show BPEL related properties with description.
Business Process Diagram
| Location | Property | Description | Dependence |
| General:Tab | Participant | Web Service interface of BPEL | |
BPEL:Tab
→ Variable:Tab | | List of global Variable | |
BPEL:Tab
→ Correlation Sets:Tab | | List of global Correlation Set | |
Variable
| Location | Property | Description | Dependence |
| BPEL:Tab | Message | Message type of Variable | |
Correlation Set
| Location | Property | Description | Dependence |
BPEL:Tab
→ Properties:Tab | | List of selected Property | |
Unspecified Task
| Location | Property | Description | Dependence |
| Assignments:Tab | | List of Copy Rule | |
Assignment (Copy Rule)
| Location | Property | Description | Dependence |
| BPEL:Tab | From | From of Copy Rule | |
| Same as above | To | To of Copy Rule | |
From Variable, To Variable
| Location | Property | Description | Dependence |
| BPEL:Tab | Variable | Variable to be copied | |
| Same as above | Part | Copy Part of Variable | Variable |
| Same as above | Query | Query of copy value | |
From Expression
| Location | Property | Description | Dependence |
| BPEL:Tab | Expression | Expression of copy value | |
From Property, To Property
| Location | Property | Description | Dependence |
| BPEL:Tab | Property | Property to be copied | |
From Partner Link
| Location | Property | Description | Dependence |
| BPEL:Tab | Partner Link | Target Partner Link | |
| Same as above | End Point Reference | Role of Partner Link | |
To Partner Link
| Location | Property | Description | Dependence |
| BPEL:Tab | Partner Link | Target Partner Link | |
Receive Task
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → General:Tab | Partner Link | Target Partner Link | |
| Same as above | Operation | Operation to be invoked | Partner Link |
| Same as above | Variable | Variable for receive message | Operation |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → Correlations:Tab | | List of Correlations | |
Correlation
| Location | Property | Description | Dependence |
| BPEL:Tab | Initiate | Is initiate | |
| Same as above | Set | Correlation Set used | |
| Same as above | Pattern | Pattern of Correlation | Task Type
Intermediate Event Type
Reply |
Send Task
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → General:Tab | Reply | Act as Reply or Invoke | |
| Same as above | Partner Link | Target Partner Link | |
| Same as above | Operation | Operation to be invoked | Partner Link
Reply |
| Same as above | Variable | Variable to be used | Operation
Reply |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → Correlations:Tab | | List of Correlations | |
Service, User, Script, Manual Task
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → General:Tab | Partner Link | Target Partner Link | |
| Same as above | Operation | Operation to be invoked | Partner Link |
| Same as above | Input Variable | Variable for send message | Operation |
| Same as above | Output Variable | Variable for receive message | Operation |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → Correlations:Tab | | Correlations | |
Timer Intermediate Event
| Location | Property | Description | Dependence |
General:Tab
→ Trigger:Specification
- → BPEL:Tab | For | Time duration of executing time | |
| Same as above | For’s Expression | Expression of time duration of executing time | |
| Same as above | Until | Fixed time | |
| Same as above | Until’s Expression | Expression of fixed time | |
Error Intermediate Event
| Location | Property | Description | Dependence |
General:Tab
→ Trigger:Specification
- → BPEL:Tab | Fault | Target Fault type | |
| Same as above | Fault Variable | Variable to be used | |
Compensation Intermediate Event

| Location | Property | Description | Dependence |
General:Tab
→ Trigger:Specification
- → BPEL:Tab | Scope | Scope to be compensated | |
Message, Rule, Link Intermediate Event
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → General:Tab | Reply | Act as Reply or Invoke | |
| Same as above | Partner Link | Target Partner Link | |
| Same as above | Operation | Operation to be invoked | Partner Link
Reply |
| Same as above | Variable | Variable to be used | Operation
Reply |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → Correlations:Tab | | List of Correlations | |
Embedded Sub Process
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → Variable:Tab | | List of local Variable | |
General:Tab
→ Type:Specification
- → BPEL:Tab
- - → Correlation Sets:Tab | | List of local Correlation Set | |
Data Gateway
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → BPEL:Tab | While | Is while or do-while | |
Event Gateway
| Location | Property | Description | Dependence |
General:Tab
→ Type:Specification
- → General:Tab | Initiate | Is initiate | |
Generating Oracle BPEL
Since Oracle BPEL is one of the supported target server, generating BPEL for Oracle is simple. However, as only basic validation is provided, an invalid BPEL may also be generated and it may fail at deployment generation.
Open Export Dialog.
Select Output Directory.
Select Target Server.
Configure Target Server.
Select Oracle BPEL Home.
Input Partner Link Map.
Check Auto Overwrite if overwrite existing files.
Start Export.
Wait until export finished.
Review Export Result. Double click on the list item may open a dialog with file content.
Debug Feature. Since it is not easy to debug a diagram with message only, an export details is provided.
Export Details
Export Details is the actual steps of exporting BPEL for debugging usage. In exporting BPEL, there are six major procedures. Each procedure depends on its previous procedure and will be executed one by one. Any errors within the procedure will be stored, and then try to continue the procedure. If procedure has error occurred, the next procedure will not be executed and the whole progress will be canceled.
The Export Trace dialog box is used to display the steps of each procedure. In other words, it show the diagram’s execution sequence of each procedure. With the Export Trace dialog box, it is possible to show details by double-clicking on a list item. However, some items are not possible to visualize. Therefore, double-clicking on those items will have no effect.
Deploying and testing BPEL
After generated Oracle BPEL, a BPEL suitcase bpel_*.jar will be created by bpelc at the selected output directory. If file does not exist, there must be problem with the diagram. Please refer to the export details and try to fix it.
Deploy BPEL into Oracle
Open browser and login to Oracle BPEL console.
Click Deploy New Process on Dashboard.
Select created BPEL suitcase and click deploy.
Click deployed process.
Input value for message.
Create process instance by sending message.
View the flow of instance.
View returned message.
Samples
Click on the link below to download:
-
-
-
-
The BPEL suitcase descriptor file exported from Simple Example.vpp.
bpel.xml