This is an automated email from the ASF dual-hosted git repository.
dockerzhang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/inlong.git
The following commit(s) were added to refs/heads/master by this push:
new 5c16b6df40 [INLONG-10438][Manager] GetConfig does not throw an
exception when obtaining the zk address fails (#10439)
5c16b6df40 is described below
commit 5c16b6df4008b0ffc06396feda5b2e776c60c6d0
Author: fuweng11 <[email protected]>
AuthorDate: Mon Jun 17 19:11:29 2024 +0800
[INLONG-10438][Manager] GetConfig does not throw an exception when
obtaining the zk address fails (#10439)
---
.../apache/inlong/manager/service/core/impl/AgentServiceImpl.java | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git
a/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/AgentServiceImpl.java
b/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/AgentServiceImpl.java
index 522bdc1022..edb36d884f 100644
---
a/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/AgentServiceImpl.java
+++
b/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/AgentServiceImpl.java
@@ -340,10 +340,9 @@ public class AgentServiceImpl implements AgentService {
.clusterTagList(clusterTagList)
.build();
List<InlongClusterEntity> agentZkCluster =
clusterMapper.selectByCondition(pageRequest);
- if (CollectionUtils.isEmpty(agentZkCluster)) {
- throw new BusinessException("zk cluster for ha not found for
cluster tag=" + request.getClusterTag());
+ if (CollectionUtils.isNotEmpty(agentZkCluster)) {
+ agentConfigInfo.setZkUrl(agentZkCluster.get(0).getUrl());
}
- agentConfigInfo.setZkUrl(agentZkCluster.get(0).getUrl());
AgentClusterInfo clusterInfo = (AgentClusterInfo)
clusterService.getOne(
null, request.getClusterName(), ClusterType.AGENT);