Skip to content
Merged
Show file tree
Hide file tree
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
5 changes: 3 additions & 2 deletions src/v/cluster/archival/purger.cc
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
#include "cluster/topics_frontend.h"
#include "config/configuration.h"
#include "config/node_config.h"
#include "container/chunked_hash_map.h"
#include "hashing/xx.h"

namespace {
Expand Down Expand Up @@ -355,8 +356,8 @@ ss::future<housekeeping_job::run_result> purger::run(run_quota_t quota) {
}

// Take a copy, as we will iterate over it asynchronously
cluster::topic_table::lifecycle_markers_t markers
= _topic_table.get_lifecycle_markers();
chunked_vector<cluster::topic_table::lifecycle_markers_t::value_type>
markers{std::from_range, _topic_table.get_lifecycle_markers()};

const auto my_global_position = get_global_position();

Expand Down
2 changes: 1 addition & 1 deletion src/v/cluster/controller_snapshot.h
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ struct topics_t
chunked_hash_map<model::topic_namespace, topic_t> topics;
raft::group_id highest_group_id;

absl::node_hash_map<
chunked_hash_map<
nt_revision,
nt_lifecycle_marker,
nt_revision_hash,
Expand Down
3 changes: 2 additions & 1 deletion src/v/cluster/topic_table.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1718,7 +1718,8 @@ ss::future<> topic_table::apply_snapshot(

// Lifecycle markers is a simple static collection without notifications
// etc, so we can just copy directly into place.
_lifecycle_markers = controller_snap.topics.lifecycle_markers;
_lifecycle_markers.replace(
controller_snap.topics.lifecycle_markers.values().copy());

reset_partitions_to_force_reconfigure(
controller_snap.topics.partitions_to_force_recover);
Expand Down
2 changes: 1 addition & 1 deletion src/v/cluster/topic_table.h
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ class topic_table {
topic_id_mapping_t _by_id;
};

using lifecycle_markers_t = absl::node_hash_map<
using lifecycle_markers_t = chunked_hash_map<
nt_revision,
nt_lifecycle_marker,
nt_revision_hash,
Expand Down
5 changes: 3 additions & 2 deletions src/v/redpanda/admin/server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@
#include <limits>
#include <memory>
#include <numeric>
#include <ranges>
#include <stdexcept>
#include <system_error>
#include <type_traits>
Expand Down Expand Up @@ -4676,8 +4677,8 @@ admin_server::get_cloud_storage_lifecycle(std::unique_ptr<ss::http::request>) {

auto& topic_table = _controller->get_topics_state().local();

cluster::topic_table::lifecycle_markers_t markers
= topic_table.get_lifecycle_markers();
chunked_vector<cluster::topic_table::lifecycle_markers_t::value_type>
markers{std::from_range, topic_table.get_lifecycle_markers()};

// Hack: persuade json response to always include the field even if empty
response.markers._set = true;
Expand Down
Loading