1
0
mirror of https://github.com/ceph/ceph synced 2025-04-01 23:02:17 +00:00

crimson/osd: create msgrs in main.cc

update PG to hold references of messengers instead of pointers to them,
as their lifecycle will be managed in main.cc

Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
Kefu Chai 2019-03-20 16:34:58 +08:00
parent 93a0b49719
commit a2c84335b4
2 changed files with 3 additions and 3 deletions
src/crimson/osd

View File

@ -12,7 +12,7 @@ PG::PG(spg_t pgid,
std::string&& name,
ec_profile_t&& ec_profile,
cached_map_t osdmap,
ceph::net::Messenger* msgr)
ceph::net::Messenger& msgr)
: pgid{pgid},
whoami{pg_shard},
pool{std::move(pool)},

View File

@ -35,7 +35,7 @@ public:
std::string&& name,
ec_profile_t&& ec_profile,
cached_map_t osdmap,
ceph::net::Messenger* msgr);
ceph::net::Messenger& msgr);
epoch_t get_osdmap_epoch() const;
const pg_info_t& get_info() const;
@ -67,5 +67,5 @@ private:
pg_shard_set_t actingset, upset;
cached_map_t osdmap;
ceph::net::Messenger* msgr = nullptr;
ceph::net::Messenger& msgr;
};