Skip to content

Commit

Permalink
Merge pull request #21570 from vbotbuildovich/backport-pr-21556-v24.1…
Browse files Browse the repository at this point in the history
….x-774

[v24.1.x] cst/config: Disable trim carryover
  • Loading branch information
piyushredpanda authored Jul 22, 2024
2 parents b2246ae + 1a6f794 commit 62a7617
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
5 changes: 5 additions & 0 deletions src/v/cloud_storage/tests/cache_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
#include <boost/test/unit_test.hpp>

#include <chrono>
#include <cstdint>
#include <fstream>
#include <optional>
#include <stdexcept>
Expand Down Expand Up @@ -565,6 +566,10 @@ FIXTURE_TEST(test_log_segment_cleanup, cache_test_fixture) {
}

FIXTURE_TEST(test_cache_carryover_trim, cache_test_fixture) {
scoped_config cfg;
cfg.get("cloud_storage_cache_trim_carryover_bytes")
.set_value(uint32_t{256_KiB});

std::string write_buf(1_MiB, ' ');
random_generators::fill_buffer_randomchars(
write_buf.data(), write_buf.size());
Expand Down
7 changes: 4 additions & 3 deletions src/v/config/configuration.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2379,10 +2379,11 @@ configuration::configuration()
"over to the next trim operation. This parameter sets a limit on the "
"memory occupied by objects that can be carried over from one trim to "
"next, and allows cache to quickly unblock readers before starting the "
"directory inspection.",
{.needs_restart = needs_restart::no, .visibility = visibility::tunable},
"directory inspection (deprecated)",
{.needs_restart = needs_restart::no,
.visibility = visibility::deprecated},
// This roughly translates to around 1000 carryover file names
256_KiB)
0_KiB)
, cloud_storage_cache_check_interval_ms(
*this,
"cloud_storage_cache_check_interval",
Expand Down

0 comments on commit 62a7617

Please sign in to comment.