feat(inkless:switch): auto-enable remote.storage.enable on diskless topic creation#619
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR ensures that when diskless topic remote-storage consolidation is enabled, newly created diskless topics automatically persist remote.storage.enable=true into the topic’s config records, so operators don’t need to explicitly include it in the create request.
Changes:
- Thread a new controller flag (
disklessRemoteStorageConsolidationEnabled) from broker config →QuorumController→ReplicationControlManager. - Add
remote.storage.enable=trueto CreateTopics response configs for diskless topics when consolidation is enabled. - Persist a
ConfigRecordforremote.storage.enable=trueon diskless topic creation when consolidation is enabled (if absent).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java | Adds response + metadata-log persistence of remote.storage.enable=true for diskless topics under consolidation. |
| metadata/src/main/java/org/apache/kafka/controller/QuorumController.java | Plumbs the consolidation-enabled flag into ReplicationControlManager.Builder. |
| core/src/main/scala/kafka/server/ControllerServer.scala | Passes the broker config flag into the QuorumController builder. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
3d37655 to
6f0ac71
Compare
6f0ac71 to
3b200f4
Compare
3b200f4 to
dbf57cb
Compare
dbf57cb to
1a4e615
Compare
1a4e615 to
b9bb45e
Compare
b9bb45e to
bdafb26
Compare
bdafb26 to
1220968
Compare
1220968 to
2fc2041
Compare
Base automatically changed from
jeqo/kc-149-diskless-remote-storage-config
to
main
May 28, 2026 13:20
9313c53 to
ae7279d
Compare
…opic creation When consolidation is enabled and a diskless topic is created, automatically persist remote.storage.enable=true in the topic config records. This ensures diskless topics always have remote storage in the consolidated model without requiring the operator to explicitly include it in the create request. Also rejects creation with remote.storage.enable explicitly set to a non-true value, and excludes system topics from the auto-enable logic (they are never diskless). Follows the same pattern as the existing diskless.enable auto-persist logic in validConfigRecords(). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ae7279d to
f985d56
Compare
giuseppelillo
requested changes
May 28, 2026
Rename disklessEnabledForRemotePolicy → disklessEnabledOnCreation since the variable is now used for both the remote policy and consolidation auto-enable logic. Also assert diskless.enable=true ConfigRecord in the defaultDisklessEnable test for completeness. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
giuseppelillo
approved these changes
May 28, 2026
giuseppelillo
pushed a commit
that referenced
this pull request
May 29, 2026
…opic creation (#619) When consolidation is enabled and a diskless topic is created, automatically persist remote.storage.enable=true in the topic config records. This ensures diskless topics always have remote storage in the consolidated model without requiring the operator to explicitly include it in the create request. Also rejects creation with remote.storage.enable explicitly set to a non-true value, and excludes system topics from the auto-enable logic (they are never diskless). Follows the same pattern as the existing diskless.enable auto-persist logic in validConfigRecords(). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
giuseppelillo
pushed a commit
that referenced
this pull request
May 29, 2026
…opic creation (#619) When consolidation is enabled and a diskless topic is created, automatically persist remote.storage.enable=true in the topic config records. This ensures diskless topics always have remote storage in the consolidated model without requiring the operator to explicitly include it in the create request. Also rejects creation with remote.storage.enable explicitly set to a non-true value, and excludes system topics from the auto-enable logic (they are never diskless). Follows the same pattern as the existing diskless.enable auto-persist logic in validConfigRecords(). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
When consolidation is enabled and a diskless topic is created, automatically persist remote.storage.enable=true in the topic config records. This ensures diskless topics always have remote storage in the consolidated model without requiring the operator to explicitly include it in the create request.
Also rejects creation with remote.storage.enable explicitly set to a non-true value, and excludes system topics from the auto-enable logic (they are never diskless).
Follows the same pattern as the existing diskless.enable auto-persist logic in validConfigRecords().