[PATCH v1 01/33] gossiper: drop unused field from loaded_endpoint_state

0 views
Skip to first unread message

Gleb Natapov

<gleb@scylladb.com>
unread,
Feb 24, 2025, 6:08:45 AMFeb 24
to scylladb-dev@googlegroups.com
---
gms/gossiper.hh | 1 -
gms/gossiper.cc | 3 ---
2 files changed, 4 deletions(-)

diff --git a/gms/gossiper.hh b/gms/gossiper.hh
index f3d5dd631cb..72263b730ec 100644
--- a/gms/gossiper.hh
+++ b/gms/gossiper.hh
@@ -75,7 +75,6 @@ struct loaded_endpoint_state {
gms::inet_address endpoint;
std::unordered_set<dht::token> tokens;
std::optional<locator::endpoint_dc_rack> opt_dc_rack;
- std::optional<gms::versioned_value> opt_status;
};

/**
diff --git a/gms/gossiper.cc b/gms/gossiper.cc
index 714c0e0e3bb..b48867f79e0 100644
--- a/gms/gossiper.cc
+++ b/gms/gossiper.cc
@@ -2222,9 +2222,6 @@ future<> gossiper::add_saved_endpoint(locator::host_id host_id, gms::loaded_endp
ep_state.add_application_state(gms::application_state::DC, gms::versioned_value::datacenter(st.opt_dc_rack->dc));
ep_state.add_application_state(gms::application_state::RACK, gms::versioned_value::datacenter(st.opt_dc_rack->rack));
}
- if (st.opt_status) {
- ep_state.add_application_state(gms::application_state::STATUS, std::move(*st.opt_status));
- }
auto generation = ep_state.get_heart_beat_state().get_generation();
co_await replicate(ep, std::move(ep_state), permit.id());
_unreachable_endpoints[ep] = now();
--
2.47.1

Benny Halevy

<bhalevy@scylladb.com>
unread,
Feb 27, 2025, 6:11:17 AMFeb 27
to Gleb Natapov, scylladb-dev@googlegroups.com
Is STATUS set somewhere else on a different code path?
Or is the STATUS application state not used period -
in which case we can delete a lot of code around it also elsewhere.

Gleb Natapov

<gleb@scylladb.com>
unread,
Feb 27, 2025, 6:23:01 AMFeb 27
to Benny Halevy, scylladb-dev@googlegroups.com
On Thu, Feb 27, 2025 at 01:11:11PM +0200, Benny Halevy wrote:
> Is STATUS set somewhere else on a different code path?
> Or is the STATUS application state not used period -
> in which case we can delete a lot of code around it also elsewhere.
>
Only this code path does not set it any longer. STATUS state itself is
very much used.
--
Gleb.
Reply all
Reply to author
Forward
0 new messages