I have a spring-cloud-stream-kafka project. The following is an abbreviated section of application.yaml. I am interested in injecting the value for the property spring.cloud.stream.kafka.bindings.myNamedChannel.dlqPartitions
into code:
spring:
cloud:
stream:
kafka:
bindings:
myNamedChannel-in-0:
consumer:
start-offset: earliest
enable-dlq: true
dlq-partitions: 4
dlq-name: myNamedChannel-dlt
I have tried permutations on the following without any success. Is something like this possible?
@Value("${spring.cloud.stream.kafka.bindings.myNamedChannel.consumer.dlqPartitions}")
private int CONTEXT_RETRY_PARTITION_COUNT;