Chat with us, powered by LiveChat
Hello World in Oracle BPEL 12c
Managing people in turbulence-Conflict management, organizational approach
21 julio, 2017
Create Managed Servers using WLST
27 julio, 2017

Oracle BPEL as part of the components provided by Oracle SOA Suite, allows us to perform the orchestration of services as a process flow.

Therefore, BPEL provides us with benefits such as the reuse of services, more flexible applications to the changes required by the organization, complexity reduction and price reduction of an integration.

We will see below how a BPEL process is created, making the name Hello World.

PriFirst we will open JDeveloper 12c, the latest version available 12.2.1.2 and we will create a new application, this will be of type SOA:

To this we will put a name, as well as the project:

We will name the Compound and we will select a Compound application with a BPEL process:

After hitting the Finish button, the window will appear where we will configure our BPEL process, we will configure the name, type, input and output parameters of our process. For the input and output parameters we will use the following example XSD.

XSD input:

Here’s where we’ll send a message that can have sender, recipient and the body of the message. Copy XSD message Input mensajeEntrada

XSD output:

Here’s where we’ll show the message concatenated with the name of the sender. Copy XSD message Output mensajeSalida

The configuration of our BPEL process will be configured as follows:

Note: in our example we have selected that the process will be Synchronous because we will need the process to return a response after execution.

Our process will appear next, where we will see the start point receiveInput and end of the replyOutput process:

Now we are going to add an Assignment Activity, which we can find in the components for BPEL and that allows us to make assignments to the variables or elements as part of our payload:

We drag it and place it between the start and end points of the process:

Note:\after adding the Assignment Activity, a warning icon will appear next to the activity, due to the fact that it has not been implemented.

Once we have added the activity to the process, we will double click it to perform the assignment as part of the example and the following window will appear where we can see the input and output parameters that we specified before when we set up the BPEL process:

Note: the assignment is made from left to right.

As in the example we will show the result of the concatenation of 2 elements of the input parameter, we will need an expression, for this we drag the expression icon and drop it on the output element «body» of the output parameter:

Subsequently, the following window will appear where we can build our expression to assign a value to the output element «body»:

Here we will use the «concat» function to concatenate the 2 elements of type String. Select the function and click on the «Insert Into Expression» button:

Note: Note: The «concat» function can be found among the String functions.

This function will concatenate 2 or more character strings that we specify as parameters. Therefore, we will add the body and sender elements as we did with the function. The expression should be as follows:

We click on the «OK» button to return to the assignment window. We will see that now for the «body» element there are connectors that indicate where the information for this element comes from:

We click on the «OK» button to return to the BPEL process. We will notice that the warning icon that had the assignment activity has now disappeared.

Now we deploy the BPEL on our SOA server and we will test the operation of our process.

Once it has been deployed, we obtain the WSDL of our service, which can be obtained from the Enterprise Manager.

I will use SoapUI to test our BPEL, I will create a new SOAP type project and to this I will add the WSDL of the BPEL:

A «Request» will be created automatically with which we can test our service, to which we will add the following test values, in the sender «Rinnovo» and in the «World» body:

Press the green button to run the test and we will see that the service responds to us with the concatenation of our entered parameters:

As we can see the service works as we designed it, we concatenate the word «Hello» to the word «World» and the word «From:» we concatenate «Rinnovo».

Why does our BPEL have a WSDL?

Because when we were configuring our BPEL we marked the option that was exposed as a service, this allows us to interact with our BPEL service. Recall also that being a component SOA, SOAP or REST are the preferred communication protocols.

If we see the compound that is generated as part of an SOA application, we can see that our BPEL appears in the Components and that in the Exposed Services section the entry that allows us to expose our BPEL as a SOAP service appears and therefore be consumed as well as We did in the test:

2 Comments

  1. Marck dice:

    Hola una pregunta, al momento de crear el proyecto no me sale la pantalla donde se meten la entrada y salidas, me podría ayudar con eso de favor.