|
Spring Integration | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.integration.context.IntegrationObjectSupport org.springframework.integration.handler.AbstractMessageHandler org.springframework.integration.router.AbstractMessageRouter
public abstract class AbstractMessageRouter
Base class for Message Routers.
Field Summary |
---|
Fields inherited from class org.springframework.integration.handler.AbstractMessageHandler |
---|
logger |
Fields inherited from interface org.springframework.core.Ordered |
---|
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE |
Constructor Summary | |
---|---|
AbstractMessageRouter()
|
Method Summary | |
---|---|
protected abstract Collection<MessageChannel> |
determineTargetChannels(Message<?> message)
Subclasses must implement this method to return the target channels for a given Message. |
String |
getComponentType()
Subclasses may implement this method to provide component type information. |
protected MessagingTemplate |
getMessagingTemplate()
Provides MessagingTemplate access for subclasses. |
protected void |
handleMessageInternal(Message<?> message)
|
void |
setApplySequence(boolean applySequence)
Specify whether to apply the sequence number and size headers to the messages prior to sending to the recipient channels. |
void |
setDefaultOutputChannel(MessageChannel defaultOutputChannel)
Set the default channel where Messages should be sent if channel resolution fails to return any channels. |
void |
setIgnoreSendFailures(boolean ignoreSendFailures)
Specify whether send failures for one or more of the recipients should be ignored. |
void |
setResolutionRequired(boolean resolutionRequired)
Set whether this router should always be required to resolve at least one channel. |
void |
setTimeout(long timeout)
Set the timeout for sending a message to the resolved channel. |
Methods inherited from class org.springframework.integration.handler.AbstractMessageHandler |
---|
getOrder, handleMessage, setOrder, setShouldTrack |
Methods inherited from class org.springframework.integration.context.IntegrationObjectSupport |
---|
afterPropertiesSet, getBeanFactory, getComponentName, getConversionService, getRequiredMetadataPersister, getTaskScheduler, onInit, setBeanFactory, setBeanName, setComponentName, setConversionService, setTaskScheduler, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.springframework.integration.context.NamedComponent |
---|
getComponentName |
Constructor Detail |
---|
public AbstractMessageRouter()
Method Detail |
---|
public void setDefaultOutputChannel(MessageChannel defaultOutputChannel)
resolutionRequired
.
public void setTimeout(long timeout)
public void setResolutionRequired(boolean resolutionRequired)
public void setIgnoreSendFailures(boolean ignoreSendFailures)
false
meaning that an Exception
will be thrown whenever a send fails. To override this and suppress
Exceptions, set the value to true
.
public void setApplySequence(boolean applySequence)
false
meaning that sequence headers will
not be applied. If planning to use an Aggregator downstream with
the default correlation and completion strategies, you should set this
flag to true
.
public String getComponentType()
IntegrationObjectSupport
getComponentType
in interface NamedComponent
getComponentType
in class AbstractMessageHandler
protected MessagingTemplate getMessagingTemplate()
MessagingTemplate
access for subclasses.
protected void handleMessageInternal(Message<?> message)
handleMessageInternal
in class AbstractMessageHandler
protected abstract Collection<MessageChannel> determineTargetChannels(Message<?> message)
|
Spring Integration | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |