public class SubscribableKafkaChannel extends AbstractKafkaChannel implements SubscribableChannel, ManageableSmartLifecycle
AbstractMessageChannel.ChannelInterceptorListIntegrationManagement.ManagementOverrideslogger, topicinterceptors, metersEXPRESSION_PARSERINDEFINITE_TIMEOUTMETER_PREFIX, RECEIVE_COUNTER_NAME, SEND_TIMER_NAME| Constructor and Description |
|---|
SubscribableKafkaChannel(org.springframework.kafka.core.KafkaOperations<?,?> template,
org.springframework.kafka.config.KafkaListenerContainerFactory<?> factory,
String channelTopic)
Construct an instance with the provided parameters.
|
| Modifier and Type | Method and Description |
|---|---|
protected MessageDispatcher |
createDispatcher() |
int |
getPhase() |
boolean |
isAutoStartup() |
boolean |
isRunning() |
protected void |
onInit()
Subclasses may implement this for initialization logic.
|
void |
setAutoStartup(boolean autoStartup)
Set the auto startup.
|
void |
setPhase(int phase)
Set the phase.
|
void |
start() |
void |
stop() |
void |
stop(Runnable callback) |
boolean |
subscribe(MessageHandler handler) |
boolean |
unsubscribe(MessageHandler handler) |
doSend, getGroupId, setGroupIdaddInterceptor, addInterceptor, destroy, getComponentType, getFullChannelName, getIChannelInterceptorList, getIntegrationPatternType, getInterceptors, getMetricsCaptor, getOverrides, isLoggingEnabled, registerMetricsCaptor, removeInterceptor, removeInterceptor, send, send, setDatatypes, setInterceptors, setLoggingEnabled, setMessageConverter, setShouldTrackafterPropertiesSet, 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, waitsend, sendgetManagedName, getManagedType, getThisAs, setManagedName, setManagedTypegetBeanName, getComponentNamepublic SubscribableKafkaChannel(org.springframework.kafka.core.KafkaOperations<?,?> template,
org.springframework.kafka.config.KafkaListenerContainerFactory<?> factory,
String channelTopic)
template - template for sending.factory - factory for creating a container for receiving.channelTopic - the topic.public int getPhase()
getPhase in interface PhasedgetPhase in interface SmartLifecyclepublic void setPhase(int phase)
phase - the phase.Phasedpublic boolean isRunning()
isRunning in interface LifecycleisRunning in interface ManageableLifecyclepublic void setAutoStartup(boolean autoStartup)
autoStartup - true to automatically start.SmartLifecyclepublic boolean isAutoStartup()
isAutoStartup in interface SmartLifecycleprotected void onInit()
IntegrationObjectSupportonInit in class AbstractMessageChannelprotected MessageDispatcher createDispatcher()
public void start()
start in interface Lifecyclestart in interface ManageableLifecyclepublic void stop()
stop in interface Lifecyclestop in interface ManageableLifecyclepublic void stop(Runnable callback)
stop in interface SmartLifecyclepublic boolean subscribe(MessageHandler handler)
subscribe in interface SubscribableChannelpublic boolean unsubscribe(MessageHandler handler)
unsubscribe in interface SubscribableChannel