mirror of
https://github.com/ceph/ceph
synced 2025-02-21 01:47:25 +00:00
osd/PG: move shutdown into PG
Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
parent
c454184d5e
commit
40a92a1f56
@ -3298,6 +3298,13 @@ void PG::init(
|
||||
write_if_dirty(*t);
|
||||
}
|
||||
|
||||
void PG::shutdown()
|
||||
{
|
||||
lock();
|
||||
on_shutdown();
|
||||
unlock();
|
||||
}
|
||||
|
||||
#pragma GCC diagnostic ignored "-Wpragmas"
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
|
@ -446,7 +446,8 @@ public:
|
||||
void get_pg_stats(std::function<void(const pg_stat_t&, epoch_t lec)> f);
|
||||
void with_heartbeat_peers(std::function<void(int)> f);
|
||||
|
||||
virtual void shutdown() = 0;
|
||||
void shutdown();
|
||||
virtual void on_shutdown() = 0;
|
||||
|
||||
bool get_must_scrub() const {
|
||||
return scrubber.must_scrub;
|
||||
|
@ -11676,13 +11676,6 @@ void PrimaryLogPG::clear_async_reads()
|
||||
}
|
||||
}
|
||||
|
||||
void PrimaryLogPG::shutdown()
|
||||
{
|
||||
lock();
|
||||
on_shutdown();
|
||||
unlock();
|
||||
}
|
||||
|
||||
void PrimaryLogPG::on_shutdown()
|
||||
{
|
||||
dout(10) << __func__ << dendl;
|
||||
|
@ -1824,8 +1824,7 @@ public:
|
||||
void on_activate() override;
|
||||
void on_flushed() override;
|
||||
void on_removal(ObjectStore::Transaction *t) override;
|
||||
void shutdown() override;
|
||||
void on_shutdown();
|
||||
void on_shutdown() override;
|
||||
bool check_failsafe_full() override;
|
||||
bool check_osdmap_full(const set<pg_shard_t> &missing_on) override;
|
||||
bool maybe_preempt_replica_scrub(const hobject_t& oid) override {
|
||||
|
Loading…
Reference in New Issue
Block a user