You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by mm...@apache.org on 2018/03/16 18:02:55 UTC

[incubator-pulsar] branch master updated: PulsarClusterMetadataSetup exits with non-zero on bad args (#1398)

This is an automated email from the ASF dual-hosted git repository.

mmerli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-pulsar.git


The following commit(s) were added to refs/heads/master by this push:
     new cdaec9e  PulsarClusterMetadataSetup exits with non-zero on bad args (#1398)
cdaec9e is described below

commit cdaec9ec6b35920b9de0d6b73c6a46d402bea6bd
Author: Ivan Kelly <iv...@apache.org>
AuthorDate: Fri Mar 16 19:02:53 2018 +0100

    PulsarClusterMetadataSetup exits with non-zero on bad args (#1398)
    
    If a user passes bad arguments to PulsarClusterMetadataSetup, it
    should exit with non-zero. Otherwise, it will look like it
    succeeded (if run from a script).
    
    The fix is just to propagate the Exception after printing out the
    usage message.
---
 .../src/main/java/org/apache/pulsar/PulsarClusterMetadataSetup.java     | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pulsar-broker/src/main/java/org/apache/pulsar/PulsarClusterMetadataSetup.java b/pulsar-broker/src/main/java/org/apache/pulsar/PulsarClusterMetadataSetup.java
index 17349aa..acb5b6d 100644
--- a/pulsar-broker/src/main/java/org/apache/pulsar/PulsarClusterMetadataSetup.java
+++ b/pulsar-broker/src/main/java/org/apache/pulsar/PulsarClusterMetadataSetup.java
@@ -90,7 +90,7 @@ public class PulsarClusterMetadataSetup {
             }
         } catch (Exception e) {
             jcommander.usage();
-            return;
+            throw e;
         }
 
         log.info("Setting up cluster {} with zk={} global-zk={}", arguments.cluster, arguments.zookeeper,

-- 
To stop receiving notification emails like this one, please contact
mmerli@apache.org.