[CP] [txn-route] fix mark participants set as changed after savepoint rollback

This commit is contained in:
chinaxing 2024-02-07 18:10:25 +00:00 committed by ob-robot
parent 7eec73bbef
commit dbb5c1fc2a
3 changed files with 10 additions and 3 deletions

View File

@ -692,6 +692,14 @@ int ObTxDesc::update_part_(ObTxPart &a, const bool append)
return ret;
}
void ObTxDesc::post_rb_savepoint_(ObTxPartRefList &parts, const ObTxSEQ &savepoint)
{
ARRAY_FOREACH_NORET(parts, i) {
parts[i].last_scn_ = savepoint;
}
state_change_flags_.PARTS_CHANGED_ = true;
}
int ObTxDesc::update_clean_part(const share::ObLSID &id,
const int64_t epoch,
const ObAddr &addr)

View File

@ -601,6 +601,7 @@ private:
int add_conflict_tx_(const ObTransIDAndAddr &conflict_tx);
int merge_conflict_txs_(const ObIArray<ObTransIDAndAddr> &conflict_ids);
int update_parts_(const ObTxPartList &list);
void post_rb_savepoint_(ObTxPartRefList &parts, const ObTxSEQ &savepoint);
void implicit_start_tx_();
bool acq_commit_cb_lock_if_need_();
bool has_extra_state_() const;

View File

@ -1499,9 +1499,7 @@ int ObTransService::rollback_savepoint_(ObTxDesc &tx,
ret = OB_TRANS_TIMEOUT;
}
if (OB_SUCC(ret)) {
ARRAY_FOREACH(parts, i) {
parts[i].last_scn_ = savepoint;
}
tx.post_rb_savepoint_(parts, savepoint);
}
return ret;
}