Skip to content

feat(inkless): POD-2386 Allow remote.storage.enabled when diskless is enabled#556

Open
viktorsomogyi wants to merge 11 commits intomainfrom
svv/ts-unification-configs
Open

feat(inkless): POD-2386 Allow remote.storage.enabled when diskless is enabled#556
viktorsomogyi wants to merge 11 commits intomainfrom
svv/ts-unification-configs

Conversation

@viktorsomogyi
Copy link
Copy Markdown

@viktorsomogyi viktorsomogyi commented Mar 30, 2026

Adds the diskless.remote.storage.consolidation.enable config. When it is enabled, it will

  • allow setting diskless.enable and remote.storage.enable on new topics
  • allow setting remote.storage.enable on existing diskless topics (where diskless.enable is enabled)
    Setting remote.storag.enable on a diskless topic will be the intended way to start the consolidation of WAL segments into tiered topics.

@viktorsomogyi viktorsomogyi changed the title feat(inkless): Add TS Consolidation configs feat(inkless): Allow remote.storage.enabled when diskless too is enabled Mar 30, 2026
@viktorsomogyi viktorsomogyi marked this pull request as ready for review March 30, 2026 13:29
@viktorsomogyi viktorsomogyi changed the title feat(inkless): Allow remote.storage.enabled when diskless too is enabled feat(inkless): Allow remote.storage.enabled when diskless is enabled Mar 30, 2026
@viktorsomogyi viktorsomogyi force-pushed the svv/ts-unification-configs branch from 506e6e1 to a699d79 Compare March 31, 2026 09:36
# Conflicts:
#	core/src/test/scala/unit/kafka/log/LogConfigTest.scala
#	storage/src/main/java/org/apache/kafka/storage/internals/log/LogConfig.java

# Conflicts:
#	storage/src/main/java/org/apache/kafka/storage/internals/log/LogConfig.java

# Conflicts:
#	storage/src/main/java/org/apache/kafka/storage/internals/log/LogConfig.java
@viktorsomogyi viktorsomogyi force-pushed the svv/ts-unification-configs branch from a699d79 to cbb9eca Compare April 1, 2026 13:52
@viktorsomogyi viktorsomogyi marked this pull request as ready for review April 1, 2026 13:53
@viktorsomogyi viktorsomogyi force-pushed the svv/ts-unification-configs branch 2 times, most recently from c574bdb to 5786342 Compare April 1, 2026 14:17
@viktorsomogyi viktorsomogyi force-pushed the svv/ts-unification-configs branch from 5786342 to 12a8902 Compare April 1, 2026 14:19
s"${ServerConfigs.DISKLESS_REMOTE_STORAGE_CONSOLIDATION_ENABLE_CONFIG} requires ${ServerConfigs.DISKLESS_MANAGED_REPLICAS_ENABLE_CONFIG}=true")
require(remoteLogManagerConfig.isRemoteStorageSystemEnabled,
s"${ServerConfigs.DISKLESS_REMOTE_STORAGE_CONSOLIDATION_ENABLE_CONFIG} requires ${RemoteLogManagerConfig.REMOTE_LOG_STORAGE_SYSTEM_ENABLE_PROP}=true")
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agree it does not require allow-from-classic migration. Even though the topic type switcher work includes foundational work for TS consolidation (e.g. diskless start offset, etc) these are not guard by the feature flag.

Co-authored-by: Jorge Esteban Quilcate Otoya <jorge.quilcate@aiven.io>
@viktorsomogyi viktorsomogyi requested a review from jeqo April 2, 2026 07:59
Copy link
Copy Markdown
Contributor

@jeqo jeqo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good. Just a few more suggestions. Let's also ensure CI is passing.


public static void validateTurningOffRemoteStorageWithDelete(Map<?, ?> newConfigs, boolean wasRemoteLogEnabled, boolean isRemoteLogStorageEnabled) {
boolean isRemoteLogDeleteOnDisable = (Boolean) Utils.castToStringObjectMap(newConfigs).getOrDefault(TopicConfig.REMOTE_LOG_DELETE_ON_DISABLE_CONFIG, false);
if (wasRemoteLogEnabled && !isRemoteLogStorageEnabled && !isRemoteLogDeleteOnDisable) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to catch this no-op "config remains unchanged" pattern in the validations, e.g. in this case wasRemoteLogEnabled && !isRemoteLogStorageEnabled.
So, when validating diskless enforcements, they should only trigger when there is an actual change.

This can be useful for tooling like Terraform that always send the whole set of configs.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a number of test cases in LogConfigTest and changed the validation slightly to satisfy these test conditions.
Let me know if you need other cases covered too.

@viktorsomogyi viktorsomogyi changed the title feat(inkless): Allow remote.storage.enabled when diskless is enabled feat(inkless): POD-2386 Allow remote.storage.enabled when diskless is enabled Apr 2, 2026
Co-authored-by: Jorge Esteban Quilcate Otoya <jorge.quilcate@aiven.io>
Co-authored-by: Viktor Somogyi-Vass <viktorsomogyi@gmail.com>
Copy link
Copy Markdown
Contributor

@jeqo jeqo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A last round of suggestions to make the conditions on LogConfigHelper more explicit. Apart from this it looks good to me.

viktorsomogyi and others added 2 commits April 7, 2026 16:31
Co-authored-by: Jorge Esteban Quilcate Otoya <jorge.quilcate@aiven.io>
Copy link
Copy Markdown
Contributor

@jeqo jeqo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Forgot to publish this one 😅 should be the last one

}

@Test
def test_disklessAllowFromClassic_and_remoteStorageConsolidation_atUpdate(): Unit = {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: naming inconsistency with other tests

Suggested change
def test_disklessAllowFromClassic_and_remoteStorageConsolidation_atUpdate(): Unit = {
def testDisklessAllowFromClassicAndRemoteStorageConsolidationAtUpdate(): Unit = {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants