|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface CorrelatorDAO
Data access object representing a correlator. A correlator does not have a simple explanation: it acts as match-maker connecting messages with message consumers (i.e. BPEL pick and receive operations) across time. For each partnerLink "myRole" and operation there is one correlator.
The correlator functions as a two-sided queue: when a message is received the correlator is used to dequeue a consumer based on the keys from the message. If no consumer matches the keys in the message, the message itself is enqueued along with its keys. Conversely, when a BPEL pick/receive operation is performed, the correlator is used to dequeue a message matching a given correlation key. If no message is found, the consumer (i.e. the pick/receive operation) is enqueued along with the target key.
The end result is matching of messages to pick/receive operations, irrespective of whether the operation or the message arrives first. Make sense?
| Method Summary | |
|---|---|
void |
addRoute(java.lang.String routeGroupId,
ProcessInstanceDAO target,
int index,
CorrelationKey correlationKey)
Add a route from the given correlation key to the given process instance. |
MessageExchangeDAO |
dequeueMessage(CorrelationKey correlationKey)
Dequeue a message exchange matching a correlationKey constraint. |
void |
enqueueMessage(MessageExchangeDAO mex,
CorrelationKey[] correlationKeys)
Enqueue a message exchange to the queue with a set of correlation keys. |
MessageRouteDAO |
findRoute(CorrelationKey correlationKey)
Find a route matching the given correlation key. |
java.lang.String |
getCorrelatorId()
Get the correlator identifier. |
void |
removeRoutes(java.lang.String routeGroupId,
ProcessInstanceDAO target)
Remove all routes with the given route-group identifier. |
| Method Detail |
|---|
java.lang.String getCorrelatorId()
void enqueueMessage(MessageExchangeDAO mex,
CorrelationKey[] correlationKeys)
mex - message exchangecorrelationKeys - pre-computed set of correlation keys for this messageMessageExchangeDAO dequeueMessage(CorrelationKey correlationKey)
correlationKey - correlation correlationKey constraint
MessageRouteDAO findRoute(CorrelationKey correlationKey)
correlationKey - correlation key
void addRoute(java.lang.String routeGroupId,
ProcessInstanceDAO target,
int index,
CorrelationKey correlationKey)
routeGroupId - identifier of the group of routes to which this route belongstarget - target process instanceindex - relative order in which the route should be consideredcorrelationKey - correlation key to match
void removeRoutes(java.lang.String routeGroupId,
ProcessInstanceDAO target)
routeGroupId -
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||