Package org.springframework.kafka.config
Interface KafkaListenerContainerFactory<C extends MessageListenerContainer>
-
- Type Parameters:
C
- theMessageListenerContainer
implementation type.
- All Known Implementing Classes:
AbstractKafkaListenerContainerFactory
,ConcurrentKafkaListenerContainerFactory
public interface KafkaListenerContainerFactory<C extends MessageListenerContainer>
Factory forMessageListenerContainer
s.- See Also:
KafkaListenerEndpoint
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description C
createContainer(java.lang.String... topics)
Create and configure a container without a listener; used to create containers that are not used for KafkaListener annotations.C
createContainer(java.util.regex.Pattern topicPattern)
Create and configure a container without a listener; used to create containers that are not used for KafkaListener annotations.C
createContainer(TopicPartitionOffset... topicPartitions)
Create and configure a container without a listener; used to create containers that are not used for KafkaListener annotations.C
createListenerContainer(KafkaListenerEndpoint endpoint)
Create aMessageListenerContainer
for the givenKafkaListenerEndpoint
.
-
-
-
Method Detail
-
createListenerContainer
C createListenerContainer(KafkaListenerEndpoint endpoint)
Create aMessageListenerContainer
for the givenKafkaListenerEndpoint
. Containers created using this method are added to the listener endpoint registry.- Parameters:
endpoint
- the endpoint to configure- Returns:
- the created container
-
createContainer
C createContainer(TopicPartitionOffset... topicPartitions)
Create and configure a container without a listener; used to create containers that are not used for KafkaListener annotations. Containers created using this method are not added to the listener endpoint registry.- Parameters:
topicPartitions
- the topicPartitions to assign.- Returns:
- the container.
- Since:
- 2.3
-
createContainer
C createContainer(java.lang.String... topics)
Create and configure a container without a listener; used to create containers that are not used for KafkaListener annotations. Containers created using this method are not added to the listener endpoint registry.- Parameters:
topics
- the topics.- Returns:
- the container.
- Since:
- 2.2
-
createContainer
C createContainer(java.util.regex.Pattern topicPattern)
Create and configure a container without a listener; used to create containers that are not used for KafkaListener annotations. Containers created using this method are not added to the listener endpoint registry.- Parameters:
topicPattern
- the topicPattern.- Returns:
- the container.
- Since:
- 2.2
-
-