Skip to content

Conversation

artembilan
Copy link
Member

Fixes: #2978

If we don't create topics manually, that can be done automatically on the broker side according to its configuration.

For that goal the EmbeddedKafkaKraftBroker is missing to populate KafkaConfig.NumPartitionsProp(): "" + this.partitionsPerTopic broker property from @EmbeddedKafka configuration

  • Propagate partitionsPerTopic option down to the embedded broker(s) in the EmbeddedKafkaKraftBroker
  • Some other simple refactoring in the EmbeddedKafkaKraftBroker
  • Verify the option propagated via new unit test in the KafkaTestUtilsTests.topicAutomaticallyCreatedWithProperNumberOfPartitions()

Fixes: spring-projects#2978

If we don't create topics manually, that can be done automatically on the broker side
according to its configuration.

For that goal the `EmbeddedKafkaKraftBroker` is missing to populate
`KafkaConfig.NumPartitionsProp(): "" + this.partitionsPerTopic` broker property from
`@EmbeddedKafka` configuration

* Propagate `partitionsPerTopic` option down to the embedded broker(s) in the `EmbeddedKafkaKraftBroker`
* Some other simple refactoring in the `EmbeddedKafkaKraftBroker`
* Verify the option propagated via new unit test in the `KafkaTestUtilsTests.topicAutomaticallyCreatedWithProperNumberOfPartitions()`
@sobychacko sobychacko merged commit 8cffe22 into spring-projects:main Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Spring Kafka Wait For Assignment Failed After Update To SpringBoot 3.2.0
2 participants