cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject [04/10] cassandra git commit: Avoid starting Cassandra on JMX bind failure
Date Wed, 04 May 2016 17:05:06 GMT
Avoid starting Cassandra on JMX bind failure

Patch by Alex Petrov; reviewed by Sam Tunnicliffe for CASSANDRA-11540


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/93c5bc61
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/93c5bc61
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/93c5bc61

Branch: refs/heads/trunk
Commit: 93c5bc616e21ffa7f31266ad095ca374f2ba73a4
Parents: 3d73282
Author: Alex Petrov <oleksandr.petrov@gmail.com>
Authored: Mon Apr 18 13:47:59 2016 +0200
Committer: Sam Tunnicliffe <sam@beobal.com>
Committed: Wed May 4 17:55:47 2016 +0100

----------------------------------------------------------------------
 CHANGES.txt                                                | 1 +
 src/java/org/apache/cassandra/service/CassandraDaemon.java | 4 ++--
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/93c5bc61/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 7c7295d..0d9d3e9 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.2.7
+ * Exit JVM if JMX server fails to startup (CASSANDRA-11540)
  * Produce a heap dump when exiting on OOM (CASSANDRA-9861)
  * Avoid read repairing purgeable tombstones on range slices (CASSANDRA-11427)
  * Restore ability to filter on clustering columns when using a 2i (CASSANDRA-11510)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/93c5bc61/src/java/org/apache/cassandra/service/CassandraDaemon.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/CassandraDaemon.java b/src/java/org/apache/cassandra/service/CassandraDaemon.java
index 6f38545..7e33e9c 100644
--- a/src/java/org/apache/cassandra/service/CassandraDaemon.java
+++ b/src/java/org/apache/cassandra/service/CassandraDaemon.java
@@ -98,7 +98,7 @@ public class CassandraDaemon
         logger = LoggerFactory.getLogger(CassandraDaemon.class);
     }
 
-    private static void maybeInitJmx()
+    private void maybeInitJmx()
     {
         if (System.getProperty("com.sun.management.jmxremote.port") != null)
             return;
@@ -119,7 +119,7 @@ public class CassandraDaemon
         }
         catch (IOException e)
         {
-            logger.error("Error starting local jmx server: ", e);
+            exitOrFail(1, e.getMessage(), e.getCause());
         }
     }
 


Mime
View raw message