How can i add/override max.poll.interval.ms and max.poll.records in my .yml file in spring boot Kafka micro-service project
What i tried is but it does not work
Kafka:
consumer:
max-poll-records: 200
max-poll-interval-ms: 600000ms
Must be like this:
spring:
kafka:
consumer:
max-poll-records: 200
properties:
max.poll.interval.ms: 600000
See Spring Boot docs: https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#messaging.kafka.additional-properties
The max.poll.interval.ms
is not exposed into KafkaProperties
, therefore its original name from the ConsumerConfig
has to be used under that properties
section. Note: you also cannot use ms
since Temporal
conversion is only done for exposed properties.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With