public abstract class AbstractExecutorChannel extends AbstractSubscribableChannel implements ExecutorChannelInterceptorAware
AbstractSubscribableChannel base implementation for those inheritors
which logic may be based on the Executor.
Utilizes common operations for the AbstractDispatcher.
Implements the ExecutorChannelInterceptors logic when the message handling
is handed to the Executor.execute(Runnable).
ExecutorChannel,
PublishSubscribeChannel| Modifier and Type | Class and Description |
|---|---|
protected class |
AbstractExecutorChannel.MessageHandlingTask |
AbstractMessageChannel.ChannelInterceptorListIntegrationManagement.ManagementOverrides| Modifier and Type | Field and Description |
|---|---|
protected AbstractDispatcher |
dispatcher |
protected java.util.concurrent.Executor |
executor |
protected int |
executorInterceptorsSize |
protected java.lang.Integer |
maxSubscribers |
interceptors, metersEXPRESSION_PARSER, loggerMETER_PREFIX, RECEIVE_COUNTER_NAME, SEND_TIMER_NAME| Constructor and Description |
|---|
AbstractExecutorChannel(java.util.concurrent.Executor executor) |
| Modifier and Type | Method and Description |
|---|---|
void |
addInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor)
Add a channel interceptor to the end of the list.
|
void |
addInterceptor(int index,
org.springframework.messaging.support.ChannelInterceptor interceptor)
Add a channel interceptor to the specified index of the list.
|
IntegrationPatternType |
getIntegrationPatternType()
Return a pattern type this component implements.
|
boolean |
hasExecutorInterceptors() |
boolean |
removeInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor) |
org.springframework.messaging.support.ChannelInterceptor |
removeInterceptor(int index) |
void |
setInterceptors(java.util.List<org.springframework.messaging.support.ChannelInterceptor> interceptors)
Set the list of channel interceptors.
|
void |
setMaxSubscribers(int maxSubscribers)
Specify the maximum number of subscribers supported by the
channel's dispatcher.
|
doSend, getDispatcher, getSubscriberCount, subscribe, unsubscribeconfigureMetrics, destroy, getComponentType, getErrorRate, getFullChannelName, getIChannelInterceptorList, getInterceptors, getMaxSendDuration, getMeanErrorRate, getMeanErrorRatio, getMeanSendDuration, getMeanSendRate, getMetrics, getMetricsCaptor, getMinSendDuration, getOverrides, getSendCount, getSendCountLong, getSendDuration, getSendErrorCount, getSendErrorCountLong, getSendRate, getStandardDeviationSendDuration, getTimeSinceLastSend, isCountsEnabled, isLoggingEnabled, isStatsEnabled, onInit, registerMetricsCaptor, reset, send, send, setCountsEnabled, setDatatypes, setLoggingEnabled, setMessageConverter, setShouldTrack, setStatsEnabledafterPropertiesSet, extractTypeIfPossible, generateId, getApplicationContext, getApplicationContextId, getBeanDescription, getBeanFactory, getBeanName, getChannelResolver, getComponentName, getConversionService, getExpression, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, isInitialized, setApplicationContext, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setConversionService, setMessageBuilderFactory, setPrimaryExpression, setTaskScheduler, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetInterceptorsgetBeanName, getComponentNamesendCount, sendErrorCountprotected java.util.concurrent.Executor executor
protected AbstractDispatcher dispatcher
protected java.lang.Integer maxSubscribers
protected int executorInterceptorsSize
public AbstractExecutorChannel(@Nullable
java.util.concurrent.Executor executor)
public void setMaxSubscribers(int maxSubscribers)
maxSubscribers - The maximum number of subscribers allowed.public void setInterceptors(java.util.List<org.springframework.messaging.support.ChannelInterceptor> interceptors)
AbstractMessageChannelsetInterceptors in interface org.springframework.messaging.support.InterceptableChannelsetInterceptors in class AbstractMessageChannelinterceptors - The list of interceptors.public void addInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor)
AbstractMessageChanneladdInterceptor in interface org.springframework.messaging.support.InterceptableChanneladdInterceptor in class AbstractMessageChannelinterceptor - The interceptor.public void addInterceptor(int index,
org.springframework.messaging.support.ChannelInterceptor interceptor)
AbstractMessageChanneladdInterceptor in interface org.springframework.messaging.support.InterceptableChanneladdInterceptor in class AbstractMessageChannelindex - The index to add interceptor.interceptor - The interceptor.public boolean removeInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor)
removeInterceptor in interface org.springframework.messaging.support.InterceptableChannelremoveInterceptor in class AbstractMessageChannel@Nullable public org.springframework.messaging.support.ChannelInterceptor removeInterceptor(int index)
removeInterceptor in interface org.springframework.messaging.support.InterceptableChannelremoveInterceptor in class AbstractMessageChannelpublic boolean hasExecutorInterceptors()
hasExecutorInterceptors in interface ExecutorChannelInterceptorAwarepublic IntegrationPatternType getIntegrationPatternType()
IntegrationPatterngetIntegrationPatternType in interface IntegrationPatterngetIntegrationPatternType in class AbstractMessageChannelIntegrationPatternType this component implements.