Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

config: remove shard_local_cfg checks for tombstone_retention_ms validator #24987

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 0 additions & 22 deletions src/v/config/validators.cc
Original file line number Diff line number Diff line change
Expand Up @@ -226,28 +226,6 @@ validate_api_endpoint(const std::optional<ss::sstring>& os) {
std::optional<ss::sstring> validate_tombstone_retention_ms(
const std::optional<std::chrono::milliseconds>& ms) {
if (ms.has_value()) {
// For simplicity's sake, cloud storage enable/read/write permissions
// cannot be enabled at the same time as tombstone_retention_ms at the
// cluster level, to avoid the case in which redpanda refuses to create
// new, misconfigured topics due to cluster defaults
const auto& cloud_storage_enabled
= config::shard_local_cfg().cloud_storage_enabled;
const auto& cloud_storage_remote_write
= config::shard_local_cfg().cloud_storage_enable_remote_write;
const auto& cloud_storage_remote_read
= config::shard_local_cfg().cloud_storage_enable_remote_read;
if (
cloud_storage_enabled() || cloud_storage_remote_write()
|| cloud_storage_remote_read()) {
return fmt::format(
"cannot set {} if any of ({}, {}, {}) are enabled at the cluster "
"level",
config::shard_local_cfg().tombstone_retention_ms.name(),
cloud_storage_enabled.name(),
cloud_storage_remote_write.name(),
cloud_storage_remote_read.name());
}

if (ms.value() < 1ms || ms.value() > serde::max_serializable_ms) {
return fmt::format(
"tombstone_retention_ms should be in range: [1, {}]",
Expand Down