dout(10) << __func__ << " approx pg log length = "
<< pg_log.get_log().approx_size() << dendl;
- dout(10) << __func__ << " transaction_applied = "
- << transaction_applied << dendl;
- if (!transaction_applied)
- dout(10) << __func__ << " " << pg_whoami
- << " is backfill target" << dendl;
- pg_log.trim(trim_to, info, transaction_applied);
+ pg_log.trim(trim_to, info);
// update the local pg, pg log
dirty_info = true;
void PGLog::trim(
eversion_t trim_to,
- pg_info_t &info,
- bool transaction_applied)
+ pg_info_t &info)
{
dout(10) << __func__ << " proposed trim_to = " << trim_to << dendl;
// trim?
if (trim_to > log.tail) {
- // Don't assert for backfill_targets
- if (transaction_applied)
- assert(trim_to <= info.last_complete);
+ // We shouldn't be trimming the log past last_complete
+ assert(trim_to <= info.last_complete);
dout(10) << "trim " << log << " to " << trim_to << dendl;
log.trim(cct, trim_to, &trimmed, &trimmed_dups, &write_from_dups);
void trim(
eversion_t trim_to,
- pg_info_t &info,
- bool transaction_applied = true);
+ pg_info_t &info);
void roll_forward_to(
eversion_t roll_forward_to,