public class EventCorrelator extends Object implements Startable, Stoppable, Disposable
| Modifier and Type | Field and Description |
|---|---|
protected ListableObjectStore<EventGroup> |
eventGroups
A map of EventGroup objects.
|
protected Object |
groupsLock |
protected long |
groupTimeToLive |
protected org.apache.commons.logging.Log |
logger
logger used by this class
|
static int |
MAX_PROCESSED_GROUPS |
static String |
NO_CORRELATION_ID |
protected ObjectStore<Long> |
processedGroups |
PHASE_NAMEPHASE_NAMEPHASE_NAME| Constructor and Description |
|---|
EventCorrelator(EventCorrelatorCallback callback,
MessageProcessor timeoutMessageProcessor,
MessageInfoMapping messageInfoMapping,
MuleContext muleContext,
FlowConstruct flowConstruct,
boolean persistentStores,
String storePrefix) |
| Modifier and Type | Method and Description |
|---|---|
protected EventGroup |
addEventGroup(EventGroup group) |
protected void |
addProcessedGroup(Object id) |
void |
dispose()
A lifecycle method where implementor should free up any resources.
|
void |
forceGroupExpiry(String groupId) |
protected EventGroup |
getEventGroup(Serializable groupId) |
long |
getTimeout() |
protected void |
handleGroupExpiry(EventGroup group) |
boolean |
isFailOnTimeout() |
protected boolean |
isGroupAlreadyProcessed(Object id) |
MuleEvent |
process(MuleEvent event) |
protected void |
removeEventGroup(EventGroup group) |
void |
setFailOnTimeout(boolean failOnTimeout) |
void |
setTimeout(long timeout) |
void |
start() |
void |
stop() |
protected final transient org.apache.commons.logging.Log logger
public static final String NO_CORRELATION_ID
public static final int MAX_PROCESSED_GROUPS
protected long groupTimeToLive
protected ListableObjectStore<EventGroup> eventGroups
protected final Object groupsLock
protected ObjectStore<Long> processedGroups
public EventCorrelator(EventCorrelatorCallback callback, MessageProcessor timeoutMessageProcessor, MessageInfoMapping messageInfoMapping, MuleContext muleContext, FlowConstruct flowConstruct, boolean persistentStores, String storePrefix)
public void forceGroupExpiry(String groupId) throws MessagingException
MessagingExceptionpublic MuleEvent process(MuleEvent event) throws RoutingException
RoutingExceptionprotected EventGroup getEventGroup(Serializable groupId) throws ObjectStoreException
ObjectStoreExceptionprotected EventGroup addEventGroup(EventGroup group) throws ObjectStoreException
ObjectStoreExceptionprotected void removeEventGroup(EventGroup group) throws ObjectStoreException
ObjectStoreExceptionprotected void addProcessedGroup(Object id) throws ObjectStoreException
ObjectStoreExceptionprotected boolean isGroupAlreadyProcessed(Object id) throws ObjectStoreException
ObjectStoreExceptionpublic boolean isFailOnTimeout()
public void setFailOnTimeout(boolean failOnTimeout)
public long getTimeout()
public void setTimeout(long timeout)
protected void handleGroupExpiry(EventGroup group) throws MessagingException
MessagingExceptionpublic void start()
throws MuleException
start in interface StartableMuleExceptionpublic void stop()
throws MuleException
stop in interface StoppableMuleExceptionpublic void dispose()
Disposabledispose in interface DisposableCopyright © 2003–2015 MuleSoft, Inc.. All rights reserved.