[CP] add _ob_wait_interval_after_truncate conf for truncate
This commit is contained in:
@ -1479,3 +1479,6 @@ DEF_BOOL(_xsolapi_generate_with_clause, OB_TENANT_PARAMETER, "True",
|
|||||||
DEF_BOOL(_optimizer_group_by_placement, OB_TENANT_PARAMETER, "True",
|
DEF_BOOL(_optimizer_group_by_placement, OB_TENANT_PARAMETER, "True",
|
||||||
"enable group by placement transform rule",
|
"enable group by placement transform rule",
|
||||||
ObParameterAttr(Section::TENANT, Source::DEFAULT, EditLevel::DYNAMIC_EFFECTIVE));
|
ObParameterAttr(Section::TENANT, Source::DEFAULT, EditLevel::DYNAMIC_EFFECTIVE));
|
||||||
|
DEF_TIME(_wait_interval_after_truncate, OB_CLUSTER_PARAMETER, "30s", "[0s,)",
|
||||||
|
"time interval for waiting other servers to refresh schema after truncate",
|
||||||
|
ObParameterAttr(Section::OBSERVER, Source::DEFAULT, EditLevel::DYNAMIC_EFFECTIVE));
|
||||||
|
|||||||
@ -2147,7 +2147,7 @@ int ObTruncateTableExecutor::execute(ObExecContext &ctx, ObTruncateTableStmt &st
|
|||||||
&& consensus_schema_version >= res.task_id_) {
|
&& consensus_schema_version >= res.task_id_) {
|
||||||
break;
|
break;
|
||||||
} else if (refreshed_schema_version >= res.task_id_
|
} else if (refreshed_schema_version >= res.task_id_
|
||||||
&& ObTimeUtility::current_time() - step_time >= 10 * 1000 * 1000) { //10s
|
&& ObTimeUtility::current_time() - step_time >= GCONF._wait_interval_after_truncate) {
|
||||||
break;
|
break;
|
||||||
} else {
|
} else {
|
||||||
ob_usleep(10 * 1000);
|
ob_usleep(10 * 1000);
|
||||||
|
|||||||
@ -352,6 +352,7 @@ _temporary_file_io_area_size
|
|||||||
_trace_control_info
|
_trace_control_info
|
||||||
_tx_result_retention
|
_tx_result_retention
|
||||||
_upgrade_stage
|
_upgrade_stage
|
||||||
|
_wait_interval_after_truncate
|
||||||
_with_subquery
|
_with_subquery
|
||||||
_xa_gc_interval
|
_xa_gc_interval
|
||||||
_xa_gc_timeout
|
_xa_gc_timeout
|
||||||
|
|||||||
Reference in New Issue
Block a user