Chapter 9. Integration into business processes 275
Using the tools, you can create service bindings from Java classes, Enterprise
JavaBeans, and EIS functions that can be accessed using a J2C connector. You
open the Service Creation wizard by selecting File
→ New → Service built
from. For more details on the Service Creation wizard, refer to the WebSphere
Studio Application Developer Integration Edition help.
For the trader system process, we imported service interface descriptions for the
three services that we call from the system process:
???? The Trader J2C IMS transaction
???? The Trader integration bean of the EIS component
???? The sender bean that sends requests to the JMS-enabled Trader EIS
component
Invoking the J2C IMS service
To use an external service in a BPEL process, you create a partner link that
describes the service provider and its service. You detail the partner link by
specifying the WSDL service interface description.
The BPEL process editor creates a partner link and configures it as soon as you
drop a WSDL service description on the panel. For example, we imported the
Trader IMS service description into the service project. Select
TraderEISIMSService.wsdl and drop it on BPEL editor showing the trader
system process. From the pop-up that appears you may select the port type you
want to import. In our example, we have defined only one port type per WSDL
service description, so you can accept the default. As a result, a new partner link
is created, in our example its name is TraderEIS.
To invoke the service in the process flow, you have to add an Invoke activity and
then you select partner link, port type, and operation for the activity. To add the
Invoke activity, select the Invoke template from the palette of the BPEL editor,
and drop it on the process. In our example, we invoke different services in the
different branches of the Switch node. So, first drop an Invoke activity on the
Local EIS - J2C case of the Switch node and rename it, for example enter
InvokeIMSService.