[CP] [LogFetcher] Modify LogLevel to Avoid Printing ERROR Log

This commit is contained in:
zxlzxlzxlzxlzxl 2023-12-19 13:18:04 +00:00 committed by ob-robot
parent 513f1ed008
commit e7de54a68a
3 changed files with 18 additions and 4 deletions

View File

@ -867,7 +867,11 @@ int LSFetchCtx::get_dispatch_progress(int64_t &dispatch_progress, PartTransDispa
tls_id_.get_ls_id(),
dispatch_progress,
dispatch_info))) {
LOG_ERROR("get_dispatch_progress from part trans resolver fail", KR(ret), K(tls_id_));
if (OB_LS_NOT_EXIST != ret) {
LOG_ERROR("get_dispatch_progress from part trans resolver fail", KR(ret), K(tls_id_));
} else {
LOG_INFO("ls_not_exist when trying to get_dispatch_progress", K(tls_id_));
}
} else if (OB_UNLIKELY(OB_INVALID_TIMESTAMP == dispatch_progress)) {
ret = OB_ERR_UNEXPECTED;
LOG_ERROR("dispatch_progress is invalid", KR(ret), K(dispatch_progress), K(tls_id_), K(dispatch_info));
@ -1215,7 +1219,9 @@ int LSFetchInfoForPrint::init(LSFetchCtx &ctx)
int ret = OB_SUCCESS;
if (OB_FAIL(ctx.get_dispatch_progress(dispatch_progress_, dispatch_info_))) {
LOG_ERROR("get_dispatch_progress from LSFetchCtx fail", KR(ret), K(ctx));
if (OB_LS_NOT_EXIST != ret) {
LOG_ERROR("get_dispatch_progress from LSFetchCtx fail", KR(ret), K(ctx));
}
} else {
tps_ = ctx.get_tps();
is_discarded_ = ctx.is_discarded();

View File

@ -407,7 +407,11 @@ bool ObLogLSFetchMgr::CtxLSProgressCond::operator() (const logservice::TenantLSI
LSFetchInfoForPrint ls_fetch_info;
if (OB_FAIL(ls_fetch_info.init(*ctx))) {
LOG_ERROR("init ls_fetch_info fail", KR(ret), K(tls_id), KPC(ctx));
if (OB_LS_NOT_EXIST != ret) {
LOG_ERROR("init ls_fetch_info fail", KR(ret), K(tls_id), KPC(ctx));
} else {
ret = OB_SUCCESS;
}
} else if (OB_FAIL(ls_fetch_info_array_.push_back(ls_fetch_info))) {
LOG_ERROR("part_progress_array_ push back fail", KR(ret), K(tls_id), KPC(ctx), K(ctx_cnt_));
} else {

View File

@ -45,7 +45,11 @@ bool FetchCtxMapHBFunc::operator()(const logservice::TenantLSID &tls_id, LSFetch
if (NULL == ctx) {
// ctx is invalid, not processed
} else if (OB_FAIL(ctx->get_dispatch_progress(progress, dispatch_info))) {
LOG_ERROR("get_dispatch_progress fail", KR(ret), K(tls_id), KPC(ctx));
if (OB_LS_NOT_EXIST != ret) {
LOG_ERROR("get_dispatch_progress fail", KR(ret), K(tls_id), KPC(ctx));
} else {
ret = OB_SUCCESS;
}
}
// The progress returned by the fetch log context must be valid, and its progress value must be a valid value, underlined by the fetch log progress
else if (OB_UNLIKELY(OB_INVALID_TIMESTAMP == progress)) {