pg->publish_stats_to_osd();
}
+boost::statechart::result PG::RecoveryState::Down::react(const QueryState& q)
+{
+ q.f->open_object_section("state");
+ q.f->dump_string("name", state_name);
+ q.f->dump_stream("enter_time") << enter_time;
+ q.f->dump_string("comment",
+ "not enough up instances of this PG to go active");
+ q.f->close_section();
+ return forward_event();
+}
+
/*------Incomplete--------*/
PG::RecoveryState::Incomplete::Incomplete(my_context ctx)
: my_base(ctx),
}
}
+boost::statechart::result PG::RecoveryState::Incomplete::react(
+ const QueryState& q)
+{
+ q.f->open_object_section("state");
+ q.f->dump_string("name", state_name);
+ q.f->dump_stream("enter_time") << enter_time;
+ q.f->dump_string("comment", "not enough complete instances of this PG");
+ q.f->close_section();
+ return forward_event();
+}
+
void PG::RecoveryState::Incomplete::exit()
{
context< RecoveryMachine >().log_exit(state_name, enter_time);
struct Down : boost::statechart::state< Down, Peering>, NamedState {
explicit Down(my_context ctx);
+ typedef boost::mpl::list <
+ boost::statechart::custom_reaction< QueryState >
+ > reactions;
+ boost::statechart::result react(const QueryState& infoevt);
void exit();
};
struct Incomplete : boost::statechart::state< Incomplete, Peering>, NamedState {
typedef boost::mpl::list <
boost::statechart::custom_reaction< AdvMap >,
- boost::statechart::custom_reaction< MNotifyRec >
+ boost::statechart::custom_reaction< MNotifyRec >,
+ boost::statechart::custom_reaction< QueryState >
> reactions;
explicit Incomplete(my_context ctx);
boost::statechart::result react(const AdvMap &advmap);
boost::statechart::result react(const MNotifyRec& infoevt);
+ boost::statechart::result react(const QueryState& infoevt);
void exit();
};