Package org.springframework.kafka.config
Class MultiMethodKafkaListenerEndpoint<K,V>
- java.lang.Object
-
- org.springframework.kafka.config.AbstractKafkaListenerEndpoint<K,V>
-
- org.springframework.kafka.config.MethodKafkaListenerEndpoint<K,V>
-
- org.springframework.kafka.config.MultiMethodKafkaListenerEndpoint<K,V>
-
- Type Parameters:
K- the key type.V- the value type.
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.beans.factory.BeanFactoryAware,org.springframework.beans.factory.InitializingBean,KafkaListenerEndpoint
public class MultiMethodKafkaListenerEndpoint<K,V> extends MethodKafkaListenerEndpoint<K,V>
TheMethodKafkaListenerEndpointextension for several POJO methods based on theKafkaHandler.- Author:
- Gary Russell
- See Also:
KafkaHandler,DelegatingInvocableHandler
-
-
Constructor Summary
Constructors Constructor Description MultiMethodKafkaListenerEndpoint(java.util.List<java.lang.reflect.Method> methods, java.lang.reflect.Method defaultMethod, java.lang.Object bean)Construct an instance for the provided methods, default method and bean.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected HandlerAdapterconfigureListenerAdapter(MessagingMessageListenerAdapter<K,V> messageListener)Create aHandlerAdapterfor this listener adapter.voidsetValidator(org.springframework.validation.Validator validator)Set a payload validator.-
Methods inherited from class org.springframework.kafka.config.MethodKafkaListenerEndpoint
createMessageListener, createMessageListenerInstance, getBean, getEndpointDescription, getMessageHandlerMethodFactory, getMethod, setBean, setErrorHandler, setMessageHandlerMethodFactory, setMessagingConverter, setMethod
-
Methods inherited from class org.springframework.kafka.config.AbstractKafkaListenerEndpoint
afterPropertiesSet, getAutoStartup, getBatchToRecordAdapter, getBeanExpressionContext, getBeanFactory, getBeanResolver, getClientIdPrefix, getConcurrency, getConsumerProperties, getGroup, getGroupId, getId, getRecordFilterStrategy, getRecoveryCallback, getReplyTemplate, getResolver, getRetryTemplate, getTopicPartitionsToAssign, getTopicPattern, getTopics, isAckDiscarded, isBatchListener, isSplitIterables, isStatefulRetry, setAckDiscarded, setAutoStartup, setBatchListener, setBatchToRecordAdapter, setBeanFactory, setClientIdPrefix, setConcurrency, setConsumerProperties, setGroup, setGroupId, setId, setRecordFilterStrategy, setRecoveryCallback, setReplyHeadersConfigurer, setReplyTemplate, setRetryTemplate, setSplitIterables, setStatefulRetry, setTopicPartitions, setTopicPattern, setTopics, setupListenerContainer, toString
-
-
-
-
Constructor Detail
-
MultiMethodKafkaListenerEndpoint
public MultiMethodKafkaListenerEndpoint(java.util.List<java.lang.reflect.Method> methods, @Nullable java.lang.reflect.Method defaultMethod, java.lang.Object bean)Construct an instance for the provided methods, default method and bean.- Parameters:
methods- the methods.defaultMethod- the default method.bean- the bean.- Since:
- 2.1.3
-
-
Method Detail
-
setValidator
public void setValidator(org.springframework.validation.Validator validator)
Set a payload validator.- Parameters:
validator- the validator.- Since:
- 2.5.11
-
configureListenerAdapter
protected HandlerAdapter configureListenerAdapter(MessagingMessageListenerAdapter<K,V> messageListener)
Description copied from class:MethodKafkaListenerEndpointCreate aHandlerAdapterfor this listener adapter.- Overrides:
configureListenerAdapterin classMethodKafkaListenerEndpoint<K,V>- Parameters:
messageListener- the listener adapter.- Returns:
- the handler adapter.
-
-