- 
                Notifications
    
You must be signed in to change notification settings  - Fork 1.7k
 
Closed
Milestone
Description
In what version(s) of Spring for Apache Kafka are you seeing this issue?
2.8.6(latest)
Describe the bug
The latest Spring Kafka documentation contains outdated information about KafkaListenerContainerFactory (two generic types):
https://docs.spring.io/spring-kafka/reference/html/
@Bean
public KafkaListenerContainerFactory<?, ?> kafkaJsonListenerContainerFactory() {
    ConcurrentKafkaListenerContainerFactory<Integer, String> factory =
        new ConcurrentKafkaListenerContainerFactory<>();
    factory.setConsumerFactory(consumerFactory());
    factory.setMessageConverter(new JsonMessageConverter());
    return factory;
}
But the current version of KafkaListenerContainerFactory has only one generic type:
https://github.com/spring-projects/spring-kafka/blob/main/spring-kafka/src/main/java/org/springframework/kafka/config/KafkaListenerContainerFactory.java
public interface KafkaListenerContainerFactory<C extends MessageListenerContainer> {
To Reproduce
Expected behavior
Spring Kafka documentation should use only one generic type for KafkaListenerContainerFactory.