Signed-off-by: Neha Ojha <nojha@redhat.com>
dout(10) << __func__ << " proposed trim_to = " << trim_to << dendl;
// trim?
if (trim_to > log.tail) {
+ dout(10) << __func__ << " missing = " << missing.num_missing() << dendl;
// Don't assert for async_recovery_targets or backfill_targets
- if (transaction_applied && !async)
+ // or whenever there are missing items
+ if (transaction_applied && !async && (missing.num_missing() == 0))
assert(trim_to <= info.last_complete);
dout(10) << "trim " << log << " to " << trim_to << dendl;