Skip to content

Fix error handling and partition config bugs in KafkaMessagingProvide…#5527

Merged
bdoyle0182 merged 1 commit intoapache:masterfrom
qualtrics:fix-kafka-ensure-topic
Jan 14, 2025
Merged

Fix error handling and partition config bugs in KafkaMessagingProvide…#5527
bdoyle0182 merged 1 commit intoapache:masterfrom
qualtrics:fix-kafka-ensure-topic

Conversation

@quintenp01
Copy link
Contributor

@quintenp01 quintenp01 commented Jan 14, 2025

…r.ensureTopic

Description

Fixes two bugs in KafkaMessagingProvider.ensureTopic:

  1. Errors creating the topic were inadvertently swallowed before this change due to using Try.map instead of Try.flatMap. We observed this when the Scheduler did not abort after failing to create it's scheduler topic.
  2. Using the topic partitions configuration does not work in it's current state. This is because the number of partitions for a new topic is provided as a separate parameter rather than part of the topic configuration. This change removes partitions from the topic configuration prior to creating the topic.

Related issue and scope

  • I opened an issue to propose and discuss this change (#????)

My changes affect the following components

  • API
  • Controller
  • Message Bus (e.g., Kafka)
  • Loadbalancer
  • Scheduler
  • Invoker
  • Intrinsic actions (e.g., sequences, conductors)
  • Data stores (e.g., CouchDB)
  • Tests
  • Deployment
  • CLI
  • General tooling
  • Documentation

Types of changes

  • Bug fix (generally a non-breaking change which closes an issue).
  • Enhancement or new feature (adds new functionality).
  • Breaking change (a bug fix or enhancement which changes existing behavior).

Checklist:

  • I signed an Apache CLA.
  • I reviewed the style guides and followed the recommendations (Travis CI will check :).
  • I added tests to cover my changes.
  • My changes require further changes to the documentation.
  • I updated the documentation where necessary.

@bdoyle0182
Copy link
Contributor

LGTM

@bdoyle0182 bdoyle0182 merged commit 364ace7 into apache:master Jan 14, 2025
6 checks passed
@bdoyle0182 bdoyle0182 deleted the fix-kafka-ensure-topic branch January 14, 2025 21:56
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.

2 participants