fix load data job not release

This commit is contained in:
wjhh2008
2023-08-01 23:24:15 +00:00
committed by ob-robot
parent f8c2c0a3ba
commit c85cd26ce7

View File

@ -134,10 +134,6 @@ int ObRpcLoadDataShuffleTaskExecuteP::process()
if (OB_FAIL(ObGlobalLoadDataStatMap::getInstance()->get_job_status(task.gid_, job_status))) {
LOG_WARN("fail to get job, main thread has already quit", K(ret), K(task));
} else if (OB_FAIL(GCTX.schema_service_->get_tenant_schema_guard(MTL_ID(), schema_guard_))) {
//Confirmed with the load data owner that the inability to calculate the correct tablet_id here will not affect the execution,
//so we use the latest schema version to obtain the guard
LOG_WARN("get tenant schema guard failed", KR(ret));
} else if (OB_ISNULL(job_status)) {
ret = OB_ERR_UNEXPECTED;
LOG_WARN("job status is null", K(ret));
@ -147,6 +143,10 @@ int ObRpcLoadDataShuffleTaskExecuteP::process()
} else if (OB_ISNULL(handle)) {
ret = OB_ERR_UNEXPECTED;
LOG_ERROR("handle is null", K(ret));
} else if (OB_FAIL(GCTX.schema_service_->get_tenant_schema_guard(MTL_ID(), schema_guard_))) {
//Confirmed with the load data owner that the inability to calculate the correct tablet_id here will not affect the execution,
//so we use the latest schema version to obtain the guard
LOG_WARN("get tenant schema guard failed", KR(ret));
} else {
handle->exec_ctx.get_sql_ctx()->schema_guard_ = &schema_guard_;
if (OB_UNLIKELY(THIS_WORKER.is_timeout())) {