Skip to content

Commit

Permalink
c/hm_frontend: renamed collect_node_health to `get_current_node_hea…
Browse files Browse the repository at this point in the history
…lth`

Signed-off-by: Michał Maślanka <michal@redpanda.com>
  • Loading branch information
mmaslankaprv committed Apr 10, 2024
1 parent 550a448 commit 0c4439a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/v/cluster/health_monitor_frontend.cc
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ storage::disk_space_alert health_monitor_frontend::get_cluster_disk_health() {
* Gets cached or collects a node health report.
*/
ss::future<result<node_health_report>>
health_monitor_frontend::collect_node_health() {
health_monitor_frontend::get_current_node_health() {
return dispatch_to_backend([](health_monitor_backend& be) mutable {
return be.get_current_node_health();
});
Expand Down
5 changes: 2 additions & 3 deletions src/v/cluster/health_monitor_frontend.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,8 @@ class health_monitor_frontend

storage::disk_space_alert get_cluster_disk_health();

// Collects and returns current node health report according to provided
// filters list
ss::future<result<node_health_report>> collect_node_health();
// Collects or return cached version of current node health report.
ss::future<result<node_health_report>> get_current_node_health();

/**
* Return drain status for a given node.
Expand Down
2 changes: 1 addition & 1 deletion src/v/cluster/service.cc
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,7 @@ void clear_partition_sizes(node_health_report& report) {

ss::future<get_node_health_reply>
service::do_collect_node_health_report(get_node_health_request req) {
auto res = co_await _hm_frontend.local().collect_node_health();
auto res = co_await _hm_frontend.local().get_current_node_health();
if (res.has_error()) {
co_return get_node_health_reply{
.error = map_health_monitor_error_code(res.error())};
Expand Down

0 comments on commit 0c4439a

Please sign in to comment.