public class SubscribableJmsChannel extends AbstractJmsChannel implements BroadcastCapableChannel, ManageableSmartLifecycle
AbstractJmsChannel
implementation for message-driven subscriptions.
Also implements a BroadcastCapableChannel
to represent possible pub-sub semantics
when configured against JMS topic.AbstractMessageChannel.ChannelInterceptorList
IntegrationManagement.ManagementOverrides
interceptors, meters
EXPRESSION_PARSER, logger
INDEFINITE_TIMEOUT
DEFAULT_PHASE
METER_PREFIX, RECEIVE_COUNTER_NAME, SEND_TIMER_NAME
Constructor and Description |
---|
SubscribableJmsChannel(AbstractMessageListenerContainer container,
JmsTemplate jmsTemplate) |
Modifier and Type | Method and Description |
---|---|
void |
destroy() |
int |
getPhase() |
boolean |
isAutoStartup() |
boolean |
isBroadcast()
Return a state of this channel in regards of broadcasting capabilities.
|
boolean |
isRunning() |
void |
onInit()
Subclasses may implement this for initialization logic.
|
void |
setMaxSubscribers(int maxSubscribers)
Specify the maximum number of subscribers supported by the
channel's dispatcher.
|
void |
start() |
void |
stop() |
void |
stop(Runnable callback) |
boolean |
subscribe(MessageHandler handler) |
boolean |
unsubscribe(MessageHandler handler) |
doSend
addInterceptor, addInterceptor, getComponentType, getFullChannelName, getIChannelInterceptorList, getIntegrationPatternType, getInterceptors, getMetricsCaptor, getOverrides, isLoggingEnabled, registerMetricsCaptor, removeInterceptor, removeInterceptor, send, send, setDatatypes, setInterceptors, setLoggingEnabled, setMessageConverter, setShouldTrack
afterPropertiesSet, 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, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
send, send
getManagedName, getManagedType, getThisAs, setManagedName, setManagedType
getBeanName, getComponentName
public SubscribableJmsChannel(AbstractMessageListenerContainer container, JmsTemplate jmsTemplate)
public void setMaxSubscribers(int maxSubscribers)
maxSubscribers
- The maximum number of subscribers allowed.public boolean subscribe(MessageHandler handler)
subscribe
in interface SubscribableChannel
public boolean unsubscribe(MessageHandler handler)
unsubscribe
in interface SubscribableChannel
public boolean isBroadcast()
BroadcastCapableChannel
isBroadcast
in interface BroadcastCapableChannel
public void onInit()
IntegrationObjectSupport
onInit
in class AbstractMessageChannel
public boolean isAutoStartup()
isAutoStartup
in interface SmartLifecycle
public int getPhase()
getPhase
in interface Phased
getPhase
in interface SmartLifecycle
public boolean isRunning()
isRunning
in interface Lifecycle
isRunning
in interface ManageableLifecycle
public void start()
start
in interface Lifecycle
start
in interface ManageableLifecycle
public void stop()
stop
in interface Lifecycle
stop
in interface ManageableLifecycle
public void stop(Runnable callback)
stop
in interface SmartLifecycle
public void destroy()
destroy
in interface DisposableBean
destroy
in interface IntegrationManagement
destroy
in class AbstractMessageChannel