mirror of
https://github.com/scylladb/scylladb.git
synced 2026-05-28 10:41:12 +00:00
repair_service: Propagate topology_state_machine to repair_service
This commit is contained in:
2
main.cc
2
main.cc
@@ -1632,7 +1632,7 @@ To start the scylla server proper, simply invoke as: scylla server (or just scyl
|
||||
// both)
|
||||
supervisor::notify("starting repair service");
|
||||
auto max_memory_repair = memory::stats().total_memory() * 0.1;
|
||||
repair.start(std::ref(gossiper), std::ref(messaging), std::ref(db), std::ref(proxy), std::ref(raft_address_map), std::ref(bm), std::ref(sys_ks), std::ref(view_builder), std::ref(task_manager), std::ref(mm), max_memory_repair).get();
|
||||
repair.start(std::ref(tsm), std::ref(gossiper), std::ref(messaging), std::ref(db), std::ref(proxy), std::ref(raft_address_map), std::ref(bm), std::ref(sys_ks), std::ref(view_builder), std::ref(task_manager), std::ref(mm), max_memory_repair).get();
|
||||
auto stop_repair_service = defer_verbose_shutdown("repair service", [&repair] {
|
||||
repair.stop().get();
|
||||
});
|
||||
|
||||
@@ -3170,7 +3170,8 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
repair_service::repair_service(distributed<gms::gossiper>& gossiper,
|
||||
repair_service::repair_service(sharded<service::topology_state_machine>& tsm,
|
||||
distributed<gms::gossiper>& gossiper,
|
||||
netw::messaging_service& ms,
|
||||
sharded<replica::database>& db,
|
||||
sharded<service::storage_proxy>& sp,
|
||||
@@ -3181,7 +3182,8 @@ repair_service::repair_service(distributed<gms::gossiper>& gossiper,
|
||||
tasks::task_manager& tm,
|
||||
service::migration_manager& mm,
|
||||
size_t max_repair_memory)
|
||||
: _gossiper(gossiper)
|
||||
: _tsm(tsm)
|
||||
, _gossiper(gossiper)
|
||||
, _messaging(ms)
|
||||
, _db(db)
|
||||
, _sp(sp)
|
||||
|
||||
@@ -86,6 +86,7 @@ public:
|
||||
using host2ip_t = std::function<future<gms::inet_address> (locator::host_id)>;
|
||||
|
||||
class repair_service : public seastar::peering_sharded_service<repair_service> {
|
||||
sharded<service::topology_state_machine>& _tsm;
|
||||
distributed<gms::gossiper>& _gossiper;
|
||||
netw::messaging_service& _messaging;
|
||||
sharded<replica::database>& _db;
|
||||
@@ -115,7 +116,8 @@ class repair_service : public seastar::peering_sharded_service<repair_service> {
|
||||
future<> uninit_ms_handlers();
|
||||
|
||||
public:
|
||||
repair_service(distributed<gms::gossiper>& gossiper,
|
||||
repair_service(sharded<service::topology_state_machine>& tsm,
|
||||
distributed<gms::gossiper>& gossiper,
|
||||
netw::messaging_service& ms,
|
||||
sharded<replica::database>& db,
|
||||
sharded<service::storage_proxy>& sp,
|
||||
|
||||
Reference in New Issue
Block a user