Skip to content

Commit

Permalink
Merge pull request ceph#61130 from baum/wip-baum-20241218-00
Browse files Browse the repository at this point in the history
src/nvmeof/NVMeofGwMonitorClient: remove MDS client, not needed
  • Loading branch information
baum authored Dec 19, 2024
2 parents 3d072b5 + f806872 commit 34f0475
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
6 changes: 1 addition & 5 deletions src/nvmeof/NVMeofGwMonitorClient.cc
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ NVMeofGwMonitorClient::NVMeofGwMonitorClient(int argc, const char **argv) :
monc{g_ceph_context, poolctx},
client_messenger(Messenger::create(g_ceph_context, "async", entity_name_t::CLIENT(-1), "client", getpid())),
objecter{g_ceph_context, client_messenger.get(), &monc, poolctx},
client{client_messenger.get(), &monc, &objecter},
timer(g_ceph_context, beacon_lock),
orig_argc(argc),
orig_argv(argv)
Expand Down Expand Up @@ -134,7 +133,6 @@ int NVMeofGwMonitorClient::init()
// Initialize Messenger
client_messenger->add_dispatcher_tail(this);
client_messenger->add_dispatcher_head(&objecter);
client_messenger->add_dispatcher_tail(&client);
client_messenger->start();

poolctx.start(2);
Expand Down Expand Up @@ -190,7 +188,6 @@ int NVMeofGwMonitorClient::init()
objecter.init();
objecter.enable_blocklist_events();
objecter.start();
client.init();
timer.init();

{
Expand Down Expand Up @@ -302,8 +299,7 @@ void NVMeofGwMonitorClient::shutdown()
std::lock_guard bl(beacon_lock);
timer.shutdown();
}
// client uses monc and objecter
client.shutdown();

// Stop asio threads, so leftover events won't call into shut down
// monclient/objecter.
poolctx.finish();
Expand Down
2 changes: 0 additions & 2 deletions src/nvmeof/NVMeofGwMonitorClient.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
#include "common/Timer.h"
#include "common/LogClient.h"

#include "client/Client.h"
#include "mon/MonClient.h"
#include "osdc/Objecter.h"
#include "messages/MNVMeofGwMap.h"
Expand Down Expand Up @@ -58,7 +57,6 @@ class NVMeofGwMonitorClient: public Dispatcher,
MonClient monc;
std::unique_ptr<Messenger> client_messenger;
Objecter objecter;
Client client;
std::map<NvmeGroupKey, NvmeGwMonClientStates> map;
ceph::mutex lock = ceph::make_mutex("NVMeofGw::lock");
// allow beacons to be sent independently of handle_nvmeof_gw_map
Expand Down

0 comments on commit 34f0475

Please sign in to comment.