What are Participants
Participants are the people and services that the process interacts with over the course of its execution. Communication to or from a participant is always through a Web service interface.
Participants simplify the BPEL details you need to provide for an interface. By creating participants, you can skip over some technical details in BPEL as Process Developer generates details for you.
Here are the participant types:
- •Process service consumers
Each process interacts with at least one participant: the participant that sends the service request message that starts the process. This participant is the first process service consumer. You can also create additional consumers if there are additional participants that use services provided by a process. Consumers can also provide callback service. These allow a process to request that the consumer perform operations. In BPEL, the process service consumer is equivalent to a partner link whose myRole property has been set.
- •Partner service providers
If the process needs to invoke a service to do some work for the process, it calls a service that is provided by a partner service provider. The process can also make callback services available to a partner service provider. The interface for such a callback is listed with the partner service provider that can use it. In BPEL, this participant is the equivalent to a partner link whose partnerRole property has been set.
- •Human task participants (on-premises only)
If the process needs people to accomplish some of its steps, it uses people activities. A human task participant represents the role of the person who will complete some of the activities of the process. Each human task participant lists the tasks that its role works on. In BPEL4People, a Logical People Group is created for each human task participant.
For details, see Using the Participants View.
For details on using the Participants view in conjunction with HTML form development, see Adding a New Service Operation for a Form or a Task.
Using the Participants View
The Participants view is the key starting point for developing a BPEL process. It guides you to provide the key ingredients for a process: the roles that the process and partner services play and the interface for each role. Further, once you define an interface, you can drag its operation to the Process Editor canvas to create process activities. For example, a receive activity is created from the interface operation associated with a process service consumer.
The following illustration shows an example of participants and their interfaces:
The Participants view is empty unless a process is open. The view is process-based; that is, it shows participants only for the process in focus.
In this view, you can do the following (on-premises only):
- •Create new process and service interfaces. See Creating a New Process Service Consumer Interface and Creating a New Partner Service Interface
- •Create new human task participants and their tasks for use in people activities.
- •Drag an operation (or task) to the Process Editor to create appropriate activities. See Creating New Activities from the Participants View.
Creating a New Process Service Consumer Interface
A Process Service Consumer is a participant Web service that is used in building a receive and/or reply activity. It consists of a name and an interface.
You can create a service consumer in stages:
- •Enter a name or accept the default name, Process_Consumer.
- •If interface resources are available, you can define the interface. If they are not, you can add them later, in the Properties view.
- •By completing the participant details, you are essentially creating all the required elements needed for a process' receive and reply activities.
Creating a New Partner Service Interface
A Partner Service Provider is a participant Web service that is used in building an invoke activity. It consists of a name and an interface.
You can create a partner service provider in stages:
- 1. Enter a name or accept the default name, Provider.
- 2. If interface resources are available, you can select the interface. If they are not, you can add them later, in the Properties view
When you complete the participant details, you are essentially creating all the elements needed for a process' invoke activity.
Creating a New Callback Interface
Select or create the port type and operation for a participant to call back.
Each Web service in a process, represented by receive, reply, and invoke activities, must have a service interface. The interface describes the operations provided by the service.
You can choose to add a callback interface, which allows the service provider to invoke operations on the service consumer. For example, in a service interface, the process sends an order and the partner replies with an order ID. In a callback interface, the partner can send an order shipment notice.
When you add a callback interface, Process Developer generates a standard BPEL partner link type for that participant and stores it in a WSDL. This makes the participant relationship clear for future users of the WSDL and allows new processes that use the service interface to automatically see the callback interface.
The details for creating a callback interface are the same as creating a service interface. See:
- •Creating a New Process Service Consumer Interface
- •Creating a New Partner Service Interface
Tips:
- •Process Developer adds the BPEL-required details, namely partner link type definitions, to a new WSDL. It adds definitions that need to be seen by clients of the process in a file named [process].public.wsdl. It places definitions that are private to the process (that is, partner link types for partner services) in a file named [process].public.wsdl.
- •The Callback participant displays as a child participant in the Participants view.
See also Creating New Activities from the Participants View
Clearing a Service Interface from a Participant
Remove a service interface from a participant.
You can clear a service interface from a participant from the Properties view.
- •From the Participants view or the Outline, select a participant.
- •In the Properties view. select the Dialog button in the Service Interface row.
- •In the Service Interface dialog, select the Clear button in the Interface row.
Creating New Activities from the Participants View
After creating participants and their interfaces, you can drag an operation or task to the Process Editor to create activities. These activities contain the required participant name and operation. You can then use the activity's Properties view to provide data assignments.
The following table shows the activities that the Process Developer creates when you drop an operation onto the Process Editor canvas.
Drag an operation from this participant's interface | To create this activity or activity pair |
---|
Process Service Consumer one-way operation | Receive, onMessage (if Pick is selected), or onEvent (if event handler is selected) |
Process Service Consumer two-way operation | Receive-Reply, onMessage-Reply, onEvent-Reply |
Process Service Consumer Callback | Invoke |
Partner Service Provider | Invoke |
Partner Service Provider Callback | Same activities as process service consumer for one-way and two-way operations |
Human Task Participant's task | People activity |
See also:
- •Creating a New Process Service Consumer Interface
- •Creating a New Partner Service Interface
- •Creating a New Callback Interface
- •Creating a new Human Task Participant in the Human Tasks section of this help
Creating a New Variable From an Activities Property View
Create a new process variable for a receive or other activities.
Create a new process variable for a receive onMessage, onEvent, reply, or invoke activity as follows:
- 1. Select the Properties view of an activity.
- 2. Open the Data, Input or Output tab of the activity.
- 3. For the Assignment Type, select Single Variable.
- 4. In the Variable list, select New Variable.
The variable name suggested is one of the following:
- •The qualified name of the schema element for a single-part element WSDL message
- •The local name of the message if the single-part element is an XSD type, such as string
- •For a multi-part WSDL message, the local name of the message
In the Scope field, select the process or a scope to make the variable global or local.
The Variable Type is derived from the WSDL message definition.