org.mule.routing
Class AbstractAggregator
java.lang.Object
org.mule.processor.AbstractInterceptingMessageProcessor
org.mule.routing.AbstractAggregator
- All Implemented Interfaces:
- FlowConstructAware, MuleContextAware, Initialisable, Startable, Stoppable, InterceptingMessageProcessor, MessageProcessor, Aggregator, MessageSource
- Direct Known Subclasses:
- AbstractCorrelationAggregator, BankQuotesResponseAggregator, MessageChunkAggregator, Resequencer, SimpleCollectionAggregator
public abstract class AbstractAggregator
- extends AbstractInterceptingMessageProcessor
- implements Initialisable, MuleContextAware, FlowConstructAware, Aggregator, Startable, Stoppable
AbstractEventAggregator
will aggregate a set of messages into a
single message.
EIP Reference: http://www.eaipatterns.com/Aggregator.html
eventCorrelator
protected EventCorrelator eventCorrelator
muleContext
protected MuleContext muleContext
flowConstruct
protected FlowConstruct flowConstruct
messageInfoMapping
protected MessageInfoMapping messageInfoMapping
AbstractAggregator
public AbstractAggregator()
initialise
public void initialise()
throws InitialisationException
- Description copied from interface:
Initialisable
- Method used to perform any initialisation work. If a fatal error occurs during
initialisation an
InitialisationException
should be thrown,
causing the Mule instance to shutdown. If the error is recoverable, say by
retrying to connect, a RecoverableException
should be thrown.
There is no guarantee that by throwing a Recoverable exception that the Mule
instance will not shut down.
- Specified by:
initialise
in interface Initialisable
- Throws:
InitialisationException
- if a fatal error occurs causing the Mule instance to shutdown
RecoverableException
- if an error occurs that can be recovered from
start
public void start()
throws MuleException
- Specified by:
start
in interface Startable
- Throws:
MuleException
stop
public void stop()
throws MuleException
- Specified by:
stop
in interface Stoppable
- Throws:
MuleException
setMuleContext
public void setMuleContext(MuleContext context)
- Specified by:
setMuleContext
in interface MuleContextAware
- Overrides:
setMuleContext
in class AbstractInterceptingMessageProcessor
getCorrelatorCallback
protected abstract EventCorrelatorCallback getCorrelatorCallback(MuleContext muleContext)
process
public MuleEvent process(MuleEvent event)
throws MuleException
- Description copied from interface:
MessageProcessor
- Invokes the MessageProcessor.
- Specified by:
process
in interface MessageProcessor
- Parameters:
event
- MuleEvent to be processed
- Returns:
- optional response MuleEvent
- Throws:
MuleException
expireAggregation
public void expireAggregation(String groupId)
- Specified by:
expireAggregation
in interface Aggregator
getTimeout
public long getTimeout()
setTimeout
public void setTimeout(long timeout)
- Specified by:
setTimeout
in interface Aggregator
isFailOnTimeout
public boolean isFailOnTimeout()
setFailOnTimeout
public void setFailOnTimeout(boolean failOnTimeout)
- Specified by:
setFailOnTimeout
in interface Aggregator
setFlowConstruct
public void setFlowConstruct(FlowConstruct flowConstruct)
- Specified by:
setFlowConstruct
in interface FlowConstructAware
setMessageInfoMapping
public void setMessageInfoMapping(MessageInfoMapping messageInfoMapping)
Copyright © 2003-2014 MuleSoft, Inc.. All Rights Reserved.