From: Sage Weil Date: Wed, 13 Dec 2017 14:19:59 +0000 (-0600) Subject: osd/PG: pass pool options to ObjectStore on pg create X-Git-Tag: v13.0.2~760^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F19486%2Fhead;p=ceph.git osd/PG: pass pool options to ObjectStore on pg create We were handling the load case and the pool change case, but not newly created PG. Fixes: http://tracker.ceph.com/issues/22419 Signed-off-by: Sage Weil --- diff --git a/src/osd/PG.cc b/src/osd/PG.cc index a618c4657931..3d047719724a 100644 --- a/src/osd/PG.cc +++ b/src/osd/PG.cc @@ -6051,6 +6051,13 @@ PG::RecoveryState::Initial::Initial(my_context ctx) context< RecoveryMachine >().log_enter(state_name); } +boost::statechart::result PG::RecoveryState::Initial::react(const Initialize& l) +{ + PG *pg = context< RecoveryMachine >().pg; + pg->update_store_with_options(); + return transit< Reset >(); +} + boost::statechart::result PG::RecoveryState::Initial::react(const Load& l) { PG *pg = context< RecoveryMachine >().pg; diff --git a/src/osd/PG.h b/src/osd/PG.h index 3b806d309861..d9eb451f0585 100644 --- a/src/osd/PG.h +++ b/src/osd/PG.h @@ -1982,13 +1982,14 @@ protected: void exit(); typedef boost::mpl::list < - boost::statechart::transition< Initialize, Reset >, + boost::statechart::custom_reaction< Initialize >, boost::statechart::custom_reaction< Load >, boost::statechart::custom_reaction< NullEvt >, boost::statechart::transition< boost::statechart::event_base, Crashed > > reactions; boost::statechart::result react(const Load&); + boost::statechart::result react(const Initialize&); boost::statechart::result react(const MNotifyRec&); boost::statechart::result react(const MInfoRec&); boost::statechart::result react(const MLogRec&);