feat(inkless): POD-2394 Implement read path for consolidated logs#583
Merged
feat(inkless): POD-2394 Implement read path for consolidated logs#583
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Implements consolidated-log read routing for inkless/diskless topics by preferring local UnifiedLog reads for consolidating partitions when the requested fetch offset is within the locally-available offset range, otherwise falling back to the diskless fetch path.
Changes:
- Update
ReplicaManager.fetchMessagesdiskless routing to use local LEO for consolidating topics (when consolidation is enabled). - Add unit tests covering consolidating vs non-consolidating diskless fetch routing decisions.
- Extend the consolidated diskless topics integration test to consume produced records and verify end-to-end readability.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| core/src/main/scala/kafka/server/ReplicaManager.scala | Adjusts diskless fetch routing logic to prioritize local reads for consolidating partitions based on local log end offset. |
| core/src/test/scala/unit/kafka/server/ReplicaManagerTest.scala | Adds unit tests validating the new consolidating-diskless routing behavior (local vs diskless). |
| core/src/test/java/kafka/server/InklessConsolidatedDisklessTopicsTest.java | Adds a consumer verification step after producing/tiering to ensure records can be read back. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
jeqo
reviewed
Apr 27, 2026
9de3801 to
04e9a4a
Compare
Contributor
Author
|
@jeqo resolved the comments, every comment is addressed in a separate commit to ease the review. |
jeqo
reviewed
Apr 28, 2026
Contributor
jeqo
left a comment
There was a problem hiding this comment.
LGTM, just a minor comment on one of the tests.
Consolidated read will be done by prioritizing local logs whenever possible. This means that if the log is consolidating and if the fetched offset falls in the local offset space, meaning fetched offset < localLog.logEndOffset, then read from local logs. Otherwise read from diskless. In case of diskless partitions that aren't consolidaing, read should be decided based on disklessStartOffset. That means that if there is a diskless offset, then read from the diskless offsets, otherwise read from the local log.
# Conflicts: # core/src/main/scala/kafka/server/ReplicaManager.scala
29b09e3 to
9dd62d6
Compare
jeqo
approved these changes
Apr 29, 2026
giuseppelillo
pushed a commit
that referenced
this pull request
May 7, 2026
Consolidated read will be done by prioritizing local logs whenever possible. This means that if the log is consolidating and if the fetched offset falls in the local offset space, meaning fetched offset < localLog.logEndOffset, then read from local logs. Otherwise read from diskless. In case of diskless partitions that aren't consolidaing, read should be decided based on disklessStartOffset. That means that if there is a diskless offset, then read from the diskless offsets, otherwise read from the local log.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Consolidated read will be done by prioritizing local logs whenever possible. This means that if the log is consolidating and if the fetched offset falls in the local offset space, meaning fetched offset < localLog.logEndOffset, then read from local logs. Otherwise read from diskless.
In case of diskless partitions that aren't consolidaing, read should be decided based on disklessStartOffset. That means that if there is a diskless offset, then read from the diskless offsets, otherwise read from the local log.