[MDS] fix mds_ctx must call on_abort bug when destroy
This commit is contained in:
@ -33,8 +33,9 @@ MdsCtx::~MdsCtx()
|
|||||||
bool list_empty = false;
|
bool list_empty = false;
|
||||||
{
|
{
|
||||||
MdsWLockGuard lg(lock_);
|
MdsWLockGuard lg(lock_);
|
||||||
bool list_empty = write_list_.empty();
|
list_empty = write_list_.empty();
|
||||||
if (!list_empty) {
|
if (!list_empty) {
|
||||||
|
OB_ASSERT(state_ != TwoPhaseCommitState::ON_COMMIT);// if decided, list is empty
|
||||||
MDS_LOG_RET(INFO, OB_SUCCESS, "nodes not commit or abort when mds ctx destroyed", K(*this));
|
MDS_LOG_RET(INFO, OB_SUCCESS, "nodes not commit or abort when mds ctx destroyed", K(*this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -131,8 +131,8 @@ int ObSyncTabletSeqMdsLogCb::on_success()
|
|||||||
{
|
{
|
||||||
int ret = OB_SUCCESS;
|
int ret = OB_SUCCESS;
|
||||||
ret_code_ = ret;
|
ret_code_ = ret;
|
||||||
state_ = STATE_SUCCESS;
|
|
||||||
mds_ctx_.single_log_commit(__get_scn(), __get_scn());
|
mds_ctx_.single_log_commit(__get_scn(), __get_scn());
|
||||||
|
state_ = STATE_SUCCESS;
|
||||||
try_release();
|
try_release();
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user