public class PollableKafkaChannel extends AbstractKafkaChannel implements PollableChannel, ExecutorChannelInterceptorAware
AbstractMessageChannel.ChannelInterceptorListIntegrationManagement.ManagementOverridestopicinterceptors, metersEXPRESSION_PARSER, loggerINDEFINITE_TIMEOUTMETER_PREFIX, RECEIVE_COUNTER_NAME, SEND_TIMER_NAME| Constructor and Description |
|---|
PollableKafkaChannel(org.springframework.kafka.core.KafkaOperations<?,?> template,
KafkaMessageSource<?,?> source)
Construct an instance with the provided parameters.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addInterceptor(ChannelInterceptor interceptor)
Add a channel interceptor to the end of the list.
|
void |
addInterceptor(int index,
ChannelInterceptor interceptor)
Add a channel interceptor to the specified index of the list.
|
protected Message<?> |
doReceive() |
boolean |
hasExecutorInterceptors() |
Message<?> |
receive() |
Message<?> |
receive(long timeout) |
boolean |
removeInterceptor(ChannelInterceptor interceptor) |
ChannelInterceptor |
removeInterceptor(int index) |
void |
setInterceptors(List<ChannelInterceptor> interceptors)
Set the list of channel interceptors.
|
doSend, getGroupId, setGroupIddestroy, getComponentType, getFullChannelName, getIChannelInterceptorList, getIntegrationPatternType, getInterceptors, getMetricsCaptor, getOverrides, isLoggingEnabled, onInit, registerMetricsCaptor, send, send, setDatatypes, 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, sendgetInterceptorsgetManagedName, getManagedType, getThisAs, setManagedName, setManagedTypegetBeanName, getComponentNamepublic PollableKafkaChannel(org.springframework.kafka.core.KafkaOperations<?,?> template,
KafkaMessageSource<?,?> source)
template - the template for sending.source - the source for receiving.@Nullable public Message<?> receive()
receive in interface PollableChannel@Nullable public Message<?> receive(long timeout)
receive in interface PollableChannelpublic void setInterceptors(List<ChannelInterceptor> interceptors)
AbstractMessageChannelsetInterceptors in interface InterceptableChannelsetInterceptors in class AbstractMessageChannelinterceptors - The list of interceptors.public void addInterceptor(ChannelInterceptor interceptor)
AbstractMessageChanneladdInterceptor in interface InterceptableChanneladdInterceptor in class AbstractMessageChannelinterceptor - The interceptor.public void addInterceptor(int index,
ChannelInterceptor interceptor)
AbstractMessageChanneladdInterceptor in interface InterceptableChanneladdInterceptor in class AbstractMessageChannelindex - The index to add interceptor.interceptor - The interceptor.public boolean removeInterceptor(ChannelInterceptor interceptor)
removeInterceptor in interface InterceptableChannelremoveInterceptor in class AbstractMessageChannel@Nullable public ChannelInterceptor removeInterceptor(int index)
removeInterceptor in interface InterceptableChannelremoveInterceptor in class AbstractMessageChannelpublic boolean hasExecutorInterceptors()
hasExecutorInterceptors in interface ExecutorChannelInterceptorAware