The BPEL Service Engine uses a mechanism called correlation to track the multiple, stateful, long-running exchanges of messages that typically take place between a BPEL process and its partner services.
The procedure for enabling correlation in a BPEL process includes the following initial steps, which must be performed in the WSDL file:
Define one or more properties in the WSDL file.
A property creates an association between business data and a name that can play an important role in the global context of the BPEL process. Each property consists of a globally unique name (for example, claimNumberProperty) and a type (for example, xsd:string).
Define property aliases in the WSDL file.
A property alias maps a specific property to a specific element or attribute in a message part. When you create a property alias, you must specify the property and the message.
Once you perform these steps in the WSDL file, you can create a correlation set in the BPEL process. The correlation set references one or more properties. The correlation set can then be used by message activities (Invoke, Reply, and Receive) and by the onMessage branches of Pick elements.
You can also use the BPEL Designer Navigator to add properties and property aliases to a WSDL file. For more information, see the "Adding Properties and Property Aliases to WSDL Files Using the Navigator" topic in the IDE online help.
In the WSDL view, right-click the Extensibility Elements node and choose Add -> Property.
A property node appears under the Extensibility Elements node.
If the Properties window is not visible, choose Window -> Properties.
Select the property node.
Set the name property.
You can set the ElementOrType property to a built-in simple type, such as string or date. If you added an inline schema or imported a schema, then you can select a type from the schema.
In the WSDL view, right-click the Extensibility Elements node and choose Add -> Property Alias.
A property alias node appears under the Extensibility Elements node.
If the Properties window is not visible, choose Window -> Properties.
Select the property alias node.
Specify values for the propertyName and ElementOrTypeOrMessagePart properties.
These properties enable you to map data from a message into a property value.
To add a query, right-click the property alias node and choose Add -> query.
A query node appears. The query node enables you to set the query language and the text of the query.