From 47c1e4a2c73983fcbe32dd41396a4c378d74c67e Mon Sep 17 00:00:00 2001 From: sekfung Date: Tue, 19 Nov 2024 15:54:26 +0800 Subject: [PATCH] fix: support grpc probe Signed-off-by: sekfung --- ...n-clusterManagement-applicationWorkloads-daemonsets-list.js | 1 + ...n-clusterManagement-applicationWorkloads-daemonsets-list.js | 1 + ...n-clusterManagement-applicationWorkloads-daemonsets-list.js | 1 + ...n-clusterManagement-applicationWorkloads-daemonsets-list.js | 1 + .../src/components/Containers/Components/ProbeRecord/index.tsx | 3 +++ 5 files changed, 7 insertions(+) diff --git a/locales/en/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js b/locales/en/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js index 80484e13642..585f2f33d1c 100644 --- a/locales/en/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js +++ b/locales/en/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js @@ -52,4 +52,5 @@ module.exports = { // List > Edit YAML // List > Re-create // List > Delete + GRPC_PORT: 'GRPC Port', }; diff --git a/locales/es/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js b/locales/es/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js index 4983b671ecb..8be1fba3589 100644 --- a/locales/es/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js +++ b/locales/es/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js @@ -47,4 +47,5 @@ module.exports = { TCP_PORT: 'Comprobación de puerto TCP', // List > Create > Storage Settings MOUNT_PATH_IN_USE: 'El punto de montaje ya está en uso', + GRPC_PORT: 'Comprobación de puerto GRPC', }; diff --git a/locales/tc/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js b/locales/tc/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js index b953962e4c7..563ade2bced 100644 --- a/locales/tc/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js +++ b/locales/tc/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js @@ -42,4 +42,5 @@ module.exports = { TCP_PORT: 'TCP 端口檢查', // List > Create > Storage Settings MOUNT_PATH_IN_USE: '掛載路徑已使用,請輸入其他掛載路徑。', + GRPC_PORT: 'GRPC 端口檢查', }; diff --git a/locales/zh/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js b/locales/zh/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js index 817323063a7..aa18048a28b 100644 --- a/locales/zh/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js +++ b/locales/zh/l10n-clusterManagement-applicationWorkloads-daemonsets-list.js @@ -39,4 +39,5 @@ module.exports = { TCP_PORT: 'TCP 端口', // List > Create > Storage Settings MOUNT_PATH_IN_USE: '挂载路径已被使用,请输入其他挂载路径。', + GRPC_PORT: 'GRPC 端口', }; diff --git a/packages/shared/src/components/Containers/Components/ProbeRecord/index.tsx b/packages/shared/src/components/Containers/Components/ProbeRecord/index.tsx index 22041837771..08a5a3ad9da 100644 --- a/packages/shared/src/components/Containers/Components/ProbeRecord/index.tsx +++ b/packages/shared/src/components/Containers/Components/ProbeRecord/index.tsx @@ -27,6 +27,9 @@ function ProbeRecord({ probe, title, tagType, noTime = false }: Props) { } else if ('tcpSocket' in probe) { probeType = 'TCP_PORT'; probeDetail = `Open socket on port ${probe.tcpSocket.port} (TCP)`; + } else if ('grpc' in probe) { + probeType = 'GRPC_PORT' + probeDetail = `Open grpc on port ${probe.grpc.port} (GRPC)`; } else { const { command = [] } = probe.exec; probeType = 'COMMAND';