You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2020/10/27 13:46:58 UTC

[GitHub] [iotdb] HTHou commented on a change in pull request #1868: Stop iotdb instance when RPC ip address or port is unavailable

HTHou commented on a change in pull request #1868:
URL: https://github.com/apache/iotdb/pull/1868#discussion_r512704707



##########
File path: server/src/main/java/org/apache/iotdb/db/service/RPCService.java
##########
@@ -61,12 +63,17 @@ public void initTProcessor() throws ClassNotFoundException,IllegalAccessExceptio
   public void initThriftServiceThread()
       throws IllegalAccessException, InstantiationException, ClassNotFoundException {
     IoTDBConfig config = IoTDBDescriptor.getInstance().getConfig();
-    thriftServiceThread = new ThriftServiceThread(processor,
-        getID().getName(), ThreadName.RPC_CLIENT.getName(),
-        config.getRpcAddress(), config.getRpcPort(), config.getRpcMaxConcurrentClientNum(),
-        config.getThriftServerAwaitTimeForStopService(),
-        new RPCServiceThriftHandler(impl),
-        IoTDBDescriptor.getInstance().getConfig().isRpcThriftCompressionEnable());
+    try {
+      thriftServiceThread = new ThriftServiceThread(processor,
+          getID().getName(), ThreadName.RPC_CLIENT.getName(),
+          config.getRpcAddress(), config.getRpcPort(), config.getRpcMaxConcurrentClientNum(),
+          config.getThriftServerAwaitTimeForStopService(),
+          new RPCServiceThriftHandler(impl),
+          IoTDBDescriptor.getInstance().getConfig().isRpcThriftCompressionEnable());
+    }
+    catch (RPCServiceException e) {
+      throw new IllegalAccessException(e.getMessage());

Review comment:
       Good idea.
   So do you think we should add the retries in this pr or do it in another pr later? I don't see any test failed so far.... 




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org