/* The primary may unilaterally restart the scrub process without notifying
* replicas. Unconditionally clear any existing state prior to handling
* the new reservation. */
- advance_token();
+ reset_replica_state();
bool granted{false};
if (m_pg->cct->_conf->osd_scrub_during_recovery ||
* this specific scrub session has terminated. All incoming events carrying
* the old tag will be discarded.
*/
- advance_token();
+ reset_replica_state();
}
void PgScrubber::discard_replica_reservations()
m_be.reset();
}
-// note that only applicable to the Replica:
-void PgScrubber::advance_token()
+void PgScrubber::reset_replica_state()
{
dout(10) << fmt::format("{}: prev. token:{}", __func__, m_current_token)
<< dendl;
m_current_token++;
-
- // when advance_token() is called, it is assumed that no scrubbing takes
- // place. We will, though, verify that. And if we are actually still handling
- // a stale request - both our internal state and the FSM state will be
- // cleared.
m_remote_osd_resource.reset();
replica_handling_done();
m_fsm->process_event(FullReset{});
* the current scrubbing operation is done. We should mark that fact, so that
* all events related to the previous operation can be discarded.
*/
- void advance_token();
+ void reset_replica_state();
bool is_token_current(Scrub::act_token_t received_token);