From 15e61b05d917524b436c50737c04bfdd0bd0a7e2 Mon Sep 17 00:00:00 2001 From: yuanruji Date: Wed, 16 Oct 2024 18:04:32 +0800 Subject: [PATCH] =?UTF-8?q?fix(dbm-services):=20=E4=BF=AE=E6=AD=A3?= =?UTF-8?q?=E5=A4=84=E7=90=86mysql=E4=B8=8D=E5=90=8C=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=20#7381?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../flow/engine/bamboo/scene/spider/append_deploy_ctl_flow.py | 4 +++- dbm-ui/backend/flow/utils/mysql/mysql_act_playload.py | 2 +- .../backend/ticket/builders/tendbcluster/append_deploy_ctl.py | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/dbm-ui/backend/flow/engine/bamboo/scene/spider/append_deploy_ctl_flow.py b/dbm-ui/backend/flow/engine/bamboo/scene/spider/append_deploy_ctl_flow.py index 09b372a97b..13c4c74ae3 100644 --- a/dbm-ui/backend/flow/engine/bamboo/scene/spider/append_deploy_ctl_flow.py +++ b/dbm-ui/backend/flow/engine/bamboo/scene/spider/append_deploy_ctl_flow.py @@ -72,7 +72,9 @@ def __init__(self, root_id: str, data: Optional[Dict]): self.threads = 0 self.bk_cloud_id = 0 # stream mydumper & myloader 流式备份导入,否则退化成mysqldump方式 - self.use_mydumper = True + self.use_mydumper = False + if self.data.get("use_mydumper"): + self.use_mydumper = self.data["use_mydumper"] self.stream = False if self.data.get("use_stream"): self.stream = self.data["use_stream"] diff --git a/dbm-ui/backend/flow/utils/mysql/mysql_act_playload.py b/dbm-ui/backend/flow/utils/mysql/mysql_act_playload.py index 0e73f7f40b..cbf7a39b5e 100644 --- a/dbm-ui/backend/flow/utils/mysql/mysql_act_playload.py +++ b/dbm-ui/backend/flow/utils/mysql/mysql_act_playload.py @@ -219,7 +219,7 @@ def deal_mysql_config(self, db_version: str, origin_configs: dict, init_configs: # 介质管理暂未记录介质来源属性 if db_version >= "8.0.30": is_community = True - cfg = self.deal_with_upgrade_to_mysql80(is_community=is_community, cfg=cfg) + cfg = self.deal_with_upgrade_to_mysql80(is_community=is_community, cfg=cfg) return cfg diff --git a/dbm-ui/backend/ticket/builders/tendbcluster/append_deploy_ctl.py b/dbm-ui/backend/ticket/builders/tendbcluster/append_deploy_ctl.py index 8fa8b9e8fd..4e9ba34216 100644 --- a/dbm-ui/backend/ticket/builders/tendbcluster/append_deploy_ctl.py +++ b/dbm-ui/backend/ticket/builders/tendbcluster/append_deploy_ctl.py @@ -26,7 +26,7 @@ class TenDBClusterAppendDeployCTLDetailSerializer(TendbBaseOperateDetailSerializ use_stream = serializers.BooleanField(help_text=_("是否使用mydumper流式备份迁移"), required=False, default=False) drop_before = serializers.BooleanField(help_text=_("导入到tdbctl前,是否先删除"), required=False, default=False) threads = serializers.IntegerField(help_text=_("mydumper 并发"), required=False, default=0) - use_mydumper = serializers.BooleanField(help_text=_("是否使用mydumper,myloader迁移"), required=False, default=True) + use_mydumper = serializers.BooleanField(help_text=_("是否使用mydumper,myloader迁移"), required=False, default=False) def validate(self, attrs): self.__validate_cluster(attrs=attrs)