You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2019/02/03 07:36:07 UTC

[GitHub] clintropolis commented on a change in pull request #6740: Zookeeper loss

clintropolis commented on a change in pull request #6740: Zookeeper loss
URL: https://github.com/apache/incubator-druid/pull/6740#discussion_r253290200
 
 

 ##########
 File path: server/src/main/java/org/apache/druid/curator/CuratorModule.java
 ##########
 @@ -79,10 +80,33 @@ public CuratorFramework makeCurator(CuratorConfig config, EnsembleProvider ensem
           StringUtils.format("%s:%s", config.getZkUser(), config.getZkPwd()).getBytes(StandardCharsets.UTF_8)
       );
     }
+
+    RetryPolicy retryPolicy;
+    if (config.getTerminateDruidProcessOnConnectFail()) {
+      final Runnable exitRunner = () -> {
+        try {
+          log.error("Zookeeper can't be reached, forcefully stopping lifecycle...");
+          lifecycle.stop();
+          log.error("Zookeeper can't be reached, forcefully stopping virtual machine...");
 
 Review comment:
   This should probably be `System.err.println` since `log` is probably dead after lifecycle stop. It won't explode, but it probably won't go anywhere either.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org