New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Boot 1.5 configuration properties for Kafka #73
Comments
This should maintain backwards compatibility with 1.4 - so if Boot 1.4 is on the classpath instead of Boot 1.5, we should fall back to the current configuration options. The typical use case is a Spring Cloud user using Dalston with Spring Boot 1.4. |
Based on some preliminary work on this, I realised that we need to have May be we don't set any default values in the AutoConfiguration KafkaProperties at all? |
We may override Spring Boot defaults and document how that happens in order to preserve the current behaviour of Spring Cloud Stream. What is important is for users to be able at least, to use the same property names for configuration. |
I think overriding Spring Boot defaults may not be a better option as we may not know whether the Spring Boot Let's consider the following scenario: We set the kafka producer key/value serialiser to |
We definitely cannot use |
Yeah, that's the reason I am thinking it would be better to completely remove the defaults in Spring Boot KafkaProperties. |
You can use |
@artembilan that's a good idea. I will check that out. Thank you! |
- If KafkaProperties for the KafkaAutoConfiguration is set, then use those properties for the KafkaMessageChannelBinder - For the KafkaProperties that have explicit default, override with the KafkaMessageChannelBinder defaults when the properties are not set by any of the property sources - Support the existing Kafka Producer/Consumer properties if they are set - Add tests Resolves spring-cloud#73
- If KafkaProperties for the KafkaAutoConfiguration is set, then use those properties for the KafkaMessageChannelBinder - For the KafkaProperties that have explicit default, override with the KafkaMessageChannelBinder defaults when the properties are not set by any of the property sources - Support the existing Kafka Producer/Consumer properties if they are set - Add tests Resolves spring-cloud#73
- If KafkaProperties is available from KafkaAutoConfiguration, retrieve the kafka properties and set as `KafkaBinderConfigurationProperties`' configuration property. This way, these properties are available at the top level and per-binding properties could still override when setting producer/consumer properties during binding operation - Add tests to verify the scenarios Resolves spring-cloud#73
Spring Boot 1.5 is introducing Kafka support, so we should be able to support the Kafka autoconfiguration the same way as we do with Rabbit.
The text was updated successfully, but these errors were encountered: