gossiper: Remove unused wait_for_feature_on_all_node and wait_for_feature_on_node
Remove unused check_features helper as well.
This commit is contained in:
@@ -2171,23 +2171,6 @@ void gossiper::check_knows_remote_features(sstring local_features_string, std::u
|
||||
}
|
||||
}
|
||||
|
||||
static bool check_features(std::set<sstring> features, std::set<sstring> need_features) {
|
||||
logger.debug("Checking if need_features {} in features {}", need_features, features);
|
||||
return boost::range::includes(features, need_features);
|
||||
}
|
||||
|
||||
future<> gossiper::wait_for_feature_on_all_node(std::set<sstring> features) {
|
||||
return _features_condvar.wait([this, features = std::move(features)] {
|
||||
return check_features(get_supported_features(), features);
|
||||
});
|
||||
}
|
||||
|
||||
future<> gossiper::wait_for_feature_on_node(std::set<sstring> features, inet_address endpoint) {
|
||||
return _features_condvar.wait([this, features = std::move(features), endpoint = std::move(endpoint)] {
|
||||
return check_features(get_supported_features(endpoint), features);
|
||||
});
|
||||
}
|
||||
|
||||
feature_service::feature_service() = default;
|
||||
|
||||
feature_service::~feature_service() = default;
|
||||
|
||||
@@ -579,10 +579,6 @@ private:
|
||||
std::set<sstring> get_supported_features() const;
|
||||
// Get features supported by all the nodes listed in the address/feature map
|
||||
static std::set<sstring> get_supported_features(std::unordered_map<gms::inet_address, sstring> peer_features_string);
|
||||
// Wait for features are available on all nodes this node knows about
|
||||
future<> wait_for_feature_on_all_node(std::set<sstring> features);
|
||||
// Wait for features are available on a particular node
|
||||
future<> wait_for_feature_on_node(std::set<sstring> features, inet_address endpoint);
|
||||
public:
|
||||
void check_knows_remote_features(sstring local_features_string) const;
|
||||
void check_knows_remote_features(sstring local_features_string, std::unordered_map<inet_address, sstring> peer_features_string) const;
|
||||
|
||||
Reference in New Issue
Block a user