fix: allow diskless+remote.storage on creation when allow-switch flag is on - #691
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Extends Kafka log config validation to allow creating topics with both diskless.enable=true and remote.storage.enable=true when either remote-storage consolidation is enabled or the “allow-from-classic” (allow-switch) flag is enabled, aligning topic-creation validation with tiered storage unification semantics.
Changes:
- Broadened
isDisklessConsolidationModeOnCreation()to accept either consolidation or allow-from-classic as the creation-time gate for diskless+remote. - Updated validation comment to reflect the expanded creation-time exception semantics.
- Added a unit test covering allow-from-classic-only behavior at topic creation.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| storage/src/main/java/org/apache/kafka/storage/internals/log/LogConfig.java | Allows diskless+remote topic creation when either consolidation or allow-from-classic is enabled. |
| core/src/test/scala/unit/kafka/log/LogConfigTest.scala | Adds test coverage for allow-from-classic permitting diskless+remote at creation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
… is on Extend isDisklessConsolidationModeOnCreation() to permit topic creation with both diskless=on and remote.storage=on when either the consolidation flag OR the allow-from-classic flag is enabled. This matches the tiered storage unification semantics where allow-switch + ts-consolidation are equivalent. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
tvainika
force-pushed
the
tvainika/restore-consolidated-topics
branch
from
July 9, 2026 12:20
76676c3 to
d2ae570
Compare
tvainika
marked this pull request as ready for review
July 9, 2026 13:34
jeqo
approved these changes
Jul 9, 2026
jeqo
pushed a commit
that referenced
this pull request
Jul 20, 2026
…n when allow-switch flag is on (#691) Extend isDisklessConsolidationModeOnCreation() to permit topic creation with both diskless=on and remote.storage=on when either the consolidation flag OR the allow-from-classic flag is enabled. This matches the tiered storage unification semantics where allow-switch + ts-consolidation are equivalent. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
jeqo
pushed a commit
that referenced
this pull request
Jul 20, 2026
…n when allow-switch flag is on (#691) Extend isDisklessConsolidationModeOnCreation() to permit topic creation with both diskless=on and remote.storage=on when either the consolidation flag OR the allow-from-classic flag is enabled. This matches the tiered storage unification semantics where allow-switch + ts-consolidation are equivalent. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.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.
Extend isDisklessConsolidationModeOnCreation() to permit topic creation with both diskless=on and remote.storage=on when either the consolidation flag OR the allow-from-classic flag is enabled. This matches the tiered storage unification semantics where allow-switch + ts-consolidation are equivalent.