Configure multiple producers and consumer in properties (configuration for multiple clusters in spring.kafka properties) #4255
-
|
If you are configuring producers or consumers for different clusters or with specific configurations, you have to add a custom property block and need programmatic configuration of these properties. This makes for a messie and complex application configuration file. From what I can see, it is easy to add this feature. That's why I was surprised it does not yet exist. I would like to see the configuration tree change something like this: I have created a starter that implements this new property structure. You can find it in my Github: https://github.com/chjansen/MultiKafka |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
I think there is some misunderstanding between Spring for Apache Kafka and Spring Boot. Your project link gives us |
Beta Was this translation helpful? Give feedback.
I understand your use-case and fully agree that it is a real one.
But unfortunately, that is not how Spring Boot works: we can auto-configure exactly one cluster for all the consumers and/or producers.
The rest of complexity over configuration properties looks for me like an overhead for the framework.
Yes, it is better to share your idea with Spring Boot team since we don't have here in Spring Kafka any API on the matter and our team does not have those deep knowledge of Spring Boot to judge properly.
Thanks for understanding!