bool PrimaryLogPG::check_laggy(OpRequestRef& op)
{
- if (!HAVE_FEATURE(recovery_state.get_min_upacting_features(),
- SERVER_OCTOPUS)) {
- dout(20) << __func__ << " not all upacting has SERVER_OCTOPUS" << dendl;
- return true;
- }
+ assert(HAVE_FEATURE(recovery_state.get_min_upacting_features(),
+ SERVER_OCTOPUS));
if (state_test(PG_STATE_WAIT)) {
dout(10) << __func__ << " PG is WAIT state" << dendl;
} else if (!state_test(PG_STATE_LAGGY)) {
bool PrimaryLogPG::check_laggy_requeue(OpRequestRef& op)
{
- if (!HAVE_FEATURE(recovery_state.get_min_upacting_features(),
- SERVER_OCTOPUS)) {
- return true;
- }
+ assert(HAVE_FEATURE(recovery_state.get_min_upacting_features(),
+ SERVER_OCTOPUS));
if (!state_test(PG_STATE_WAIT) && !state_test(PG_STATE_LAGGY)) {
return true; // not laggy
}
if (size)
data_subset.insert(0, size);
- if (HAVE_FEATURE(parent->min_peer_features(), SERVER_OCTOPUS)) {
- const auto it = missing.get_items().find(head);
- assert(it != missing.get_items().end());
- data_subset.intersection_of(it->second.clean_regions.get_dirty_regions());
- dout(10) << "calc_head_subsets " << head
- << " data_subset " << data_subset << dendl;
- }
+ assert(HAVE_FEATURE(parent->min_peer_features(), SERVER_OCTOPUS));
+ const auto it = missing.get_items().find(head);
+ assert(it != missing.get_items().end());
+ data_subset.intersection_of(it->second.clean_regions.get_dirty_regions());
+ dout(10) << "calc_head_subsets " << head
+ << " data_subset " << data_subset << dendl;
if (get_parent()->get_pool().allow_incomplete_clones()) {
dout(10) << __func__ << ": caching (was) enabled, skipping clone subsets" << dendl;
// pulling head or unversioned object.
// always pull the whole thing.
recovery_info.copy_subset.insert(0, (uint64_t)-1);
- if (HAVE_FEATURE(parent->min_peer_features(), SERVER_OCTOPUS))
- recovery_info.copy_subset.intersection_of(missing_iter->second.clean_regions.get_dirty_regions());
+ assert(HAVE_FEATURE(parent->min_peer_features(), SERVER_OCTOPUS));
+ recovery_info.copy_subset.intersection_of(missing_iter->second.clean_regions.get_dirty_regions());
recovery_info.size = ((uint64_t)-1);
recovery_info.object_exist = missing_iter->second.clean_regions.object_is_exist();
}
op.recovery_info.soid = soid;
op.recovery_info.version = v;
op.recovery_progress.data_complete = false;
- op.recovery_progress.omap_complete = !missing_iter->second.clean_regions.omap_is_dirty()
- && HAVE_FEATURE(parent->min_peer_features(), SERVER_OCTOPUS);
+ op.recovery_progress.omap_complete = !missing_iter->second.clean_regions.omap_is_dirty();
op.recovery_progress.data_recovered_to = 0;
op.recovery_progress.first = true;
pi.recovery_info.ss = pop->recovery_info.ss;
pi.recovery_info.version = version;
pi.recovery_info.object_exist = missing_iter->second.clean_regions.object_is_exist();
- pi.recovery_progress.omap_complete = !missing_iter->second.clean_regions.omap_is_dirty() &&
- HAVE_FEATURE(parent->min_peer_features(), SERVER_OCTOPUS);
+ pi.recovery_progress.omap_complete = !missing_iter->second.clean_regions.omap_is_dirty();
pi.lock_manager = std::move(lock_manager);
ObjectRecoveryProgress new_progress;