This is an automated email from the ASF dual-hosted git repository. haonan pushed a commit to branch ssl_between_nodes in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit 1f3a9e860fcaec2057fe7f3e0c6aa716edfa48c5 Author: HTHou <[email protected]> AuthorDate: Mon Jul 21 12:10:59 2025 +0800 fix cluster bugs --- .../iotdb/consensus/iot/client/SyncIoTConsensusServiceClient.java | 4 +++- .../iotdb/commons/client/sync/SyncConfigNodeIServiceClient.java | 4 +++- .../commons/client/sync/SyncDataNodeMPPDataExchangeServiceClient.java | 4 +++- .../iotdb/commons/client/sync/SyncPipeConsensusServiceClient.java | 4 +++- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/iotdb-core/consensus/src/main/java/org/apache/iotdb/consensus/iot/client/SyncIoTConsensusServiceClient.java b/iotdb-core/consensus/src/main/java/org/apache/iotdb/consensus/iot/client/SyncIoTConsensusServiceClient.java index 27dc5391027..43b2f60d89f 100644 --- a/iotdb-core/consensus/src/main/java/org/apache/iotdb/consensus/iot/client/SyncIoTConsensusServiceClient.java +++ b/iotdb-core/consensus/src/main/java/org/apache/iotdb/consensus/iot/client/SyncIoTConsensusServiceClient.java @@ -71,7 +71,9 @@ public class SyncIoTConsensusServiceClient extends IoTConsensusIService.Client this.printLogWhenEncounterException = property.isPrintLogWhenEncounterException(); this.endpoint = endpoint; this.clientManager = clientManager; - getInputProtocol().getTransport().open(); + if (!getInputProtocol().getTransport().isOpen()) { + getInputProtocol().getTransport().open(); + } } @Override diff --git a/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncConfigNodeIServiceClient.java b/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncConfigNodeIServiceClient.java index 2fdb9887e7e..ced2c92b4a0 100644 --- a/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncConfigNodeIServiceClient.java +++ b/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncConfigNodeIServiceClient.java @@ -73,7 +73,9 @@ public class SyncConfigNodeIServiceClient extends IConfigNodeRPCService.Client this.printLogWhenEncounterException = property.isPrintLogWhenEncounterException(); this.endpoint = endPoint; this.clientManager = clientManager; - getInputProtocol().getTransport().open(); + if (!getInputProtocol().getTransport().isOpen()) { + getInputProtocol().getTransport().open(); + } } public int getTimeout() throws SocketException { diff --git a/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncDataNodeMPPDataExchangeServiceClient.java b/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncDataNodeMPPDataExchangeServiceClient.java index 0ff739554bb..4dcde11bfac 100644 --- a/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncDataNodeMPPDataExchangeServiceClient.java +++ b/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncDataNodeMPPDataExchangeServiceClient.java @@ -73,7 +73,9 @@ public class SyncDataNodeMPPDataExchangeServiceClient extends MPPDataExchangeSer this.printLogWhenEncounterException = property.isPrintLogWhenEncounterException(); this.endpoint = endpoint; this.clientManager = clientManager; - getInputProtocol().getTransport().open(); + if (!getInputProtocol().getTransport().isOpen()) { + getInputProtocol().getTransport().open(); + } } public int getTimeout() throws SocketException { diff --git a/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncPipeConsensusServiceClient.java b/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncPipeConsensusServiceClient.java index 4755a65c650..334d3cf43fc 100644 --- a/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncPipeConsensusServiceClient.java +++ b/iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/client/sync/SyncPipeConsensusServiceClient.java @@ -73,7 +73,9 @@ public class SyncPipeConsensusServiceClient extends PipeConsensusIService.Client this.printLogWhenEncounterException = property.isPrintLogWhenEncounterException(); this.endpoint = endpoint; this.clientManager = clientManager; - getInputProtocol().getTransport().open(); + if (!getInputProtocol().getTransport().isOpen()) { + getInputProtocol().getTransport().open(); + } } public int getTimeout() throws SocketException {
