rseetham opened a new pull request, #18949: URL: https://github.com/apache/pinot/pull/18949
## Summary **Stacked on #18913** (`TopicPartitionId` introduction) — please review/merge that one first. Note: this PR's commit list will show 2 commits (the #18913 commit plus this PR's own commit) because GitHub doesn't support basing a PR on another fork's branch — the diff is against `master` until #18913 merges. Once #18913 merges, this PR's diff/commit list will automatically shrink to just this PR's own commit (`Use TopicPartitionId as primary partition identity...`). `TopicPartitionId.java` is only created once, in #18913's commit; it is not duplicated. This PR migrates internal partition-identity handling from raw `int`/`Integer` partition IDs to the `TopicPartitionId` composite key introduced in the prior PR, in preparation for supporting multiple Kafka topics per Pinot table. - Add context-aware `LLCSegmentName(String, boolean hasMultipleStreams)` that decomposes old-format composite partition IDs (e.g. `10003` -> topic 1, partition 3) at parse time when the table has multiple streams, so `TopicPartitionId` is always canonical regardless of segment format. - Migrate internal maps from `Map<Integer, ...>` to `Map<TopicPartitionId, ...>` across controller, server, query planner, segment-local, and minion tasks. - Change `assignConsumingSegment`, `computeStartOffset`, and other internal methods to accept `TopicPartitionId` directly instead of raw partition ints. - Thread `hasMultipleStreams` through `RealtimeSegmentConfig`, `MutableIndexContext`, and Lucene index constructors. - Add `TopicPartitionId.fromPartitionGroupMetadata()` for SPI boundary wrapping and `SegmentUtils.getTopicPartitionIdFromSegmentName()` as the new API. - Deprecate the now-superseded `IngestionConfigUtils` encode/decode helpers (kept for external/legacy call sites not covered by this migration). ## Test plan - [x] `test-compile` across `pinot-spi, pinot-common, pinot-controller, pinot-core, pinot-segment-local, pinot-query-planner` passes cleanly - [x] `PinotLLCRealtimeSegmentManagerTest` — 42/42 pass - [x] `IngestionDelayTrackerTest` — 9/9 pass - [x] `PinotSegmentRestletResourceTest` — 8/8 pass -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
