From 849a93f5e0afee79f6127c70fb55b6f952215ad1 Mon Sep 17 00:00:00 2001 From: liuzifeng Date: Wed, 10 Jul 2024 16:21:02 +0800 Subject: [PATCH] fix nometa init intercept --- storage/tianchi/ha_tse.cc | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/storage/tianchi/ha_tse.cc b/storage/tianchi/ha_tse.cc index ba9655c..ee3797b 100644 --- a/storage/tianchi/ha_tse.cc +++ b/storage/tianchi/ha_tse.cc @@ -402,7 +402,7 @@ bool engine_skip_ddl(MYSQL_THD thd) { bool engine_ddl_passthru(MYSQL_THD thd) { // 元数据归一初始化场景,接口流程需要走到参天 - if (is_meta_version_initialize() || is_meta_version_upgrading_force()) { + if (is_initialize() || is_meta_version_upgrading_force()) { return false; } bool is_mysql_local = user_var_set(thd, "ctc_ddl_local_enabled"); @@ -4715,18 +4715,16 @@ static int tse_init_func(void *p) { // 元数据归一流程初始化下发参天 // 主干非initialize_insecure模式,需要注册共享内存接收线程并等待参天启动完成 - if (!opt_initialize_insecure || CHECK_HAS_MEMBER(handlerton, get_inst_id)) { - ret = srv_wait_instance_startuped(); - if (ret != 0) { - tse_log_error("wait cantian instance startuped failed:%d", ret); - return HA_ERR_INITIALIZATION; - } - - ret = tse_reg_instance(); - if (ret != 0) { - tse_log_error("[CTC_INIT]:ctc_reg_instance failed:%d", ret); - return HA_ERR_INITIALIZATION; - } + ret = srv_wait_instance_startuped(); + if (ret != 0) { + tse_log_error("wait cantian instance startuped failed:%d", ret); + return HA_ERR_INITIALIZATION; + } + + ret = tse_reg_instance(); + if (ret != 0) { + tse_log_error("[CTC_INIT]:ctc_reg_instance failed:%d", ret); + return HA_ERR_INITIALIZATION; } ret = tse_check_tx_isolation(); -- Gitee