public TSConnectionInfoResp fetchAllConnections() throws IoTDBConnectionException {
    return callWithRetryAndReconnect(
            () -> client.fetchAllConnectionsInfo(), resp -> false, resp -> false)
        .getResult();
  }
reconnect if the remote datanode is unreachable retry if the status is set to needRetry
iotdb-client/session/src/main/java/org/apache/iotdb/session/SessionConnection.java