[FIX] tx data self freeze failed
This commit is contained in:
@ -515,8 +515,9 @@ int ObTenantFreezer::get_tenant_tx_data_mem_used_(int64_t &tenant_tx_data_mem_us
|
||||
int ls_cnt = 0;
|
||||
int64_t ls_tx_data_mem_used = 0;
|
||||
for (; OB_SUCC(ret) && OB_SUCC(iter->get_next(ls)); ++ls_cnt) {
|
||||
if (OB_FAIL(get_ls_tx_data_mem_used_(ls, ls_tx_data_mem_used))) {
|
||||
LOG_WARN("[TenantFreezer] fail to get tx data mem used in one ls", KR(ret));
|
||||
int tmp_ret = OB_SUCCESS;
|
||||
if (OB_TMP_FAIL(get_ls_tx_data_mem_used_(ls, ls_tx_data_mem_used))) {
|
||||
LOG_WARN("[TenantFreezer] fail to get tx data mem used in one ls", KR(ret), K(ls->get_ls_id()));
|
||||
} else {
|
||||
tenant_tx_data_mem_used += ls_tx_data_mem_used;
|
||||
}
|
||||
@ -651,12 +652,21 @@ int ObTenantFreezer::check_and_do_freeze()
|
||||
} else if (!tenant_info_.is_loaded_) {
|
||||
// do nothing
|
||||
} else if (FALSE_IT(tenant_info_.get_freeze_ctx(ctx))) {
|
||||
} else if (OB_FAIL(check_and_freeze_normal_data_(ctx))) {
|
||||
LOG_WARN("[TenantFreezer] check and freeze normal data failed.", KR(ret));
|
||||
} else if (OB_FAIL(check_and_freeze_tx_data_())) {
|
||||
LOG_WARN("[TenantFreezer] check and freeze tx data failed.", KR(ret));
|
||||
} else if (OB_FAIL(check_and_freeze_mds_table_())) {
|
||||
LOG_WARN("[TenantFreezer] check and freeze mds table failed.", KR(ret));
|
||||
} else {
|
||||
int tmp_ret = OB_SUCCESS;
|
||||
if (OB_TMP_FAIL(check_and_freeze_normal_data_(ctx))) {
|
||||
LOG_WARN("[TenantFreezer] check and freeze normal data failed.", KR(tmp_ret));
|
||||
}
|
||||
|
||||
tmp_ret = OB_SUCCESS;
|
||||
if (OB_TMP_FAIL(check_and_freeze_tx_data_())) {
|
||||
LOG_WARN("[TenantFreezer] check and freeze tx data failed.", KR(tmp_ret));
|
||||
}
|
||||
|
||||
tmp_ret = OB_SUCCESS;
|
||||
if (OB_TMP_FAIL(check_and_freeze_mds_table_())) {
|
||||
LOG_WARN("[TenantFreezer] check and freeze mds table failed.", KR(tmp_ret));
|
||||
}
|
||||
}
|
||||
|
||||
int64_t check_and_freeze_end_ts = ObTimeUtil::current_time();
|
||||
|
||||
@ -341,7 +341,7 @@ int ObTxDataMemtableMgr::get_active_memtable(ObTableHandleV2 &handle) const
|
||||
MemMgrRLockGuard lock_guard(lock_);
|
||||
if (0 == memtable_tail_) {
|
||||
ret = OB_EAGAIN;
|
||||
STORAGE_LOG(INFO, "tx data memtable is not created yet. try agagin.", K(ret), K(memtable_tail_));
|
||||
STORAGE_LOG(INFO, "tx data memtable is not created yet. try agagin.", K(ret), K(ls_id_), K(memtable_tail_));
|
||||
} else if (0 == get_memtable_count_()) {
|
||||
ret = OB_ENTRY_NOT_EXIST;
|
||||
STORAGE_LOG(WARN, "the tx data memtable manager is empty. may be offline", KR(ret), K(get_memtable_count_()));
|
||||
|
||||
Reference in New Issue
Block a user