Skip to content

KAFKA-10844: KStream mark as partitioned#22221

Open
zheguang wants to merge 4 commits intoapache:trunkfrom
zheguang:zheguang-KAFKA-10844
Open

KAFKA-10844: KStream mark as partitioned#22221
zheguang wants to merge 4 commits intoapache:trunkfrom
zheguang:zheguang-KAFKA-10844

Conversation

@zheguang
Copy link
Copy Markdown
Contributor

@zheguang zheguang commented May 6, 2026

This patch implements KIP-759: Unneeded repartition cancelling. The "unneeded" part is entirely by the user's own judgement :)

A stream with key-changing operation can be marked as partitioned as intended to avoid repartition inserted to its topology. The main use case is for aggregation by a "composite key" -- a stream partitioned by key A can readily aggregate by composite key (A, B) without repartition. The reason being given two records, if their (A, B) are equal, then their A is equal.

Test:

  • markAsPartitioned is no-op when no key changing
  • markAsPartitioned should not repartition in resulting topology
  • IQ should work when query for the original key intended by markAsPartitioned

@github-actions github-actions Bot added triage PRs from the community streams labels May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

streams triage PRs from the community

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant