I'm writing a Spring Boot application that uses Confluent KAFKA replicator and below is my Spring boot profile
spring:
kafka:
consumer:
properties:
interceptor:
classes: io.confluent.connect.replicator.offsets.ConsumerTimestampsInterceptor
timestamp:
producer:
security:
protocol: PLAINTEXT
sasl:
mechanism: NONE
I don't have Confluent KAFKA replicator in the lower environment - eg: Dev. So, I want a flag/profile property to disable/enable the above Confluent KAFKA Interceptor (ConsumerTimestampsInterceptor). How do I do it? Something like this
spring:
kafka:
consumer:
properties:
interceptor:
enabled : false
You should be able to create a dev profile (for example, application-dev.yaml) for your spring application, then remove the property altogether. There is no enabled
boolean property
Also, you shouldn't need full nesting since consumer properties are flat, anyways
spring:
kafka:
consumer:
properties:
interceptor.classes: "className"
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