You may have notice that as you were building the state machine that there was one error all along: Correlation set must have at least one property. When deployed to a server, your state machine could have several instances, each in a different state.

When an operation is called on the state machine component, you need a way to make the call on the correct instance. This is accomplished using correlation sets.

A correlation set tells the state machine which running instance to use for the given input data. It does this by examining the contents of the input data, using a specified field as a kind of key that uniquely identifies the corresponding process instance.

In WebSphere Integration Developer V6.0.2.2, these are the four steps:

1. Right-click Correlation Properties on the top-right corner of the editor and select Add Correlation Property.
2. Enter OrderNumber for the name, select int for the type, and then click OK.
3. In the OrderNumber correlation properties that opens, each operation of the business state machine displays. Click the cell next to placeOrder and then drill down to Order - orderNumber.
4. Click the cell next to orderShipped and drill down to Order - orderNumber.

0 comments: