BPEL correlation matches inbound messages with a specific process instance. When you need to associate specific data to a specific instance of a business process, you use correlation.
For example, while creating a process that verifies an account number and checks the account’s credit limit. When verified, the process makes a call to another system to check inventory and, if the item is in stock, generates a purchase order. How does the purchase order know which account is to be debited? The answer to this question is correlation.
Correlation sets are used to uniquely identify process instances. You provide each correlation set with a unique name and then define it by one or more properties. Each property has a name and a type (for example, string or integer).
The property alias for each property in the correlation set needs to be defined. A property alias is a mapping that binds the property with the input or output values.
Consider the following important points related to the Correlation Sets and Message Aggregation −
A process that contains more than one receive or pick activity must have a correlation set.
Correlation sets are initialized with values from process inbound or outbound messages.
If you have groups of messages that are associated together with one specific process, you can set up one or more correlation sets to handle.