diff --git a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterShardUpdate.ts b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterShardUpdate.ts index 1eaa450928..0cf5bcd9fb 100644 --- a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterShardUpdate.ts +++ b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterShardUpdate.ts @@ -57,6 +57,7 @@ export async function generateRedisClusterShardUpdateCloneData( groupNum: currentClusterInfo.machine_pair_cnt, currentSpecId: currentClusterInfo.cluster_spec.spec_id, dbVersion: item.db_version, + disasterToleranceLevel: currentClusterInfo.disaster_tolerance_level, specConfig: { cpu: currentClusterInfo.cluster_spec.cpu, id: currentClusterInfo.cluster_spec.spec_id, diff --git a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterTypeUpdate.ts b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterTypeUpdate.ts index b50d95c8a9..b1b287e808 100644 --- a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterTypeUpdate.ts +++ b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/clusterTypeUpdate.ts @@ -56,6 +56,7 @@ export async function generateRedisClusterTypeUpdateCloneData(ticketData: Ticket groupNum: currentClusterInfo.machine_pair_cnt, clusterTypeName: currentClusterInfo.cluster_type_name, currentSpecId: currentClusterInfo.cluster_spec.spec_id, + disasterToleranceLevel: currentClusterInfo.disaster_tolerance_level, dbVersion: item.db_version, specConfig: { cpu: currentClusterInfo.cluster_spec.cpu, diff --git a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/scaleUpdown.ts b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/scaleUpdown.ts index c1af5097f2..6e5951e5db 100644 --- a/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/scaleUpdown.ts +++ b/dbm-ui/frontend/src/hooks/useTicketCloneInfo/generateCloneData/redis/scaleUpdown.ts @@ -44,6 +44,7 @@ export async function generateRedisScaleUpdownCloneData(ticketData: TicketModel< bkCloudId: item.bk_cloud_id, clusterTypeName: clusterListMap[item.cluster_id].cluster_type_name, clusterStats: clusterListMap[item.cluster_id].cluster_stats, + disasterToleranceLevel: clusterListMap[item.cluster_id].disaster_tolerance_level, shardNum: clusterListMap[item.cluster_id].cluster_shard_num, groupNum: clusterListMap[item.cluster_id].machine_pair_cnt, version: item.db_version, diff --git a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/Index.vue b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/Index.vue index 9707269f15..74e3326dd3 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/Index.vue @@ -145,6 +145,7 @@ bkCloudId: data.bk_cloud_id, clusterTypeName: data.cluster_type_name, clusterStats: data.cluster_stats, + disasterToleranceLevel: data.disaster_tolerance_level, shardNum: data.cluster_shard_num, groupNum: data.machine_pair_cnt, machineCount: data.redis_master.length, @@ -223,7 +224,6 @@ infos, }, }; - await createTicket(params).then((data) => { window.changeConfirm = false; router.push({ diff --git a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/ClusterDeployPlan.vue b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/ClusterDeployPlan.vue index e950193eb0..2db04c84e8 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/ClusterDeployPlan.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/ClusterDeployPlan.vue @@ -85,7 +85,7 @@ - {{ t('--') }} + -- @@ -110,7 +110,7 @@ - {{ t('--') }} + -- @@ -135,7 +135,7 @@ - {{ t('--') }} + -- @@ -160,7 +160,7 @@ - {{ t('--') }} + -- @@ -176,7 +176,7 @@ - {{ t('--') }} + -- diff --git a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/RenderTargetCapacity.vue b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/RenderTargetCapacity.vue index aeb9f4ab5a..26692cc5a1 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/RenderTargetCapacity.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/RenderTargetCapacity.vue @@ -243,7 +243,7 @@ backend_group: { spec_id: localValue.spec_id, count: targetObj.value!.requireMachineGroupNum, // 机器实际需要申请的组数 - affinity: AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE', + affinity: props.rowData?.disasterToleranceLevel || AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE', }, }, }); diff --git a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/Row.vue b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/Row.vue index 31c188be06..4f4a653e22 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/Row.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/capacity-change/pages/page1/components/Row.vue @@ -89,6 +89,7 @@ bkCloudId: number; clusterTypeName: string; clusterStats: RedisModel['cluster_stats']; + disasterToleranceLevel: string; shardNum?: number; groupNum?: number; currentSepc?: string; @@ -134,6 +135,7 @@ bkCloudId: 0, clusterTypeName: '', clusterStats: {} as IDataRow['clusterStats'], + disasterToleranceLevel: '', }); interface Props { diff --git a/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/Index.vue b/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/Index.vue index b157f05b46..5ea7b0ce27 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/Index.vue @@ -259,6 +259,7 @@ clusterTypeName: item.cluster_type_name, currentSpecId: item.cluster_spec.spec_id, dbVersion: item.major_version, + disasterToleranceLevel: item.disaster_tolerance_level, specConfig: { cpu: item.cluster_spec.cpu, id: item.cluster_spec.spec_id, diff --git a/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/components/Row.vue b/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/components/Row.vue index 1a590fc244..54903d4b5f 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/components/Row.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/cluster-shard-update/pages/page1/components/Row.vue @@ -86,6 +86,7 @@ currentSpecId: number; clusterTypeName: string; dbVersion: string; + disasterToleranceLevel: string; specConfig: { cpu: { max: number; @@ -157,6 +158,7 @@ groupNum: 0, currentSpecId: 0, dbVersion: '', + disasterToleranceLevel: '', specConfig: { cpu: { max: 0, @@ -254,12 +256,12 @@ proxy: { spec_id: props.data.proxy.id, count: props.data.proxy.count, - affinity: AffinityType.CROS_SUBZONE, + affinity: props.data.disasterToleranceLevel || AffinityType.CROS_SUBZONE, }, backend_group: { spec_id: deployData.spec_id, count: deployData.count, // 机器组数 - affinity: AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE', + affinity: props.data.disasterToleranceLevel || AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE', }, }, }; diff --git a/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/Index.vue b/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/Index.vue index ba4d440c3b..3abbbab9aa 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/Index.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/Index.vue @@ -155,7 +155,6 @@ type: TicketTypes.REDIS_CLUSTER_TYPE_UPDATE, onSuccess(cloneData) { const { tableList, type, frequency } = cloneData; - tableData.value = tableList; repairAndVerifyType.value = type; repairAndVerifyFrequency.value = frequency; @@ -258,6 +257,7 @@ clusterType: item.cluster_type, machineType: item.cluster_spec.spec_machine_type, currentShardNum: item.cluster_shard_num, + disasterToleranceLevel: item.disaster_tolerance_level, groupNum: item.machine_pair_cnt, dbVersion: item.major_version, specConfig: { diff --git a/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/components/Row.vue b/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/components/Row.vue index 50f50ebf50..21692b25ed 100644 --- a/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/components/Row.vue +++ b/dbm-ui/frontend/src/views/db-manage/redis/cluster-type-update/pages/page1/components/Row.vue @@ -106,6 +106,7 @@ currentShardNum: number; groupNum: number; clusterTypeName: string; + disasterToleranceLevel: string; specConfig: { cpu: { max: number; @@ -181,6 +182,7 @@ groupNum: 0, clusterTypeName: '', currentSepc: '', + disasterToleranceLevel: '', specConfig: { cpu: { max: 0, @@ -313,7 +315,7 @@ backend_group: { spec_id: deployData.spec_id, count: deployData.count, // 机器组数 - affinity: AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE', + affinity: props.data.disasterToleranceLevel || AffinityType.CROS_SUBZONE, // 暂时固定 'CROS_SUBZONE', }, }, };