cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject [04/13] git commit: Workaround JVM NPE on JMX bind failure patch by Brandon Williams; reviewed by tjake for CASSANDRA-7254
Date Mon, 07 Jul 2014 05:14:08 GMT
Workaround JVM NPE on JMX bind failure
patch by Brandon Williams; reviewed by tjake for CASSANDRA-7254


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

Branch: refs/heads/cassandra-2.1.0
Commit: a14211fbd147ba3219103549153254fa5f09fb1c
Parents: f39cb07
Author: Jonathan Ellis <jbellis@apache.org>
Authored: Mon Jul 7 00:12:05 2014 -0500
Committer: Jonathan Ellis <jbellis@apache.org>
Committed: Mon Jul 7 00:12:57 2014 -0500

----------------------------------------------------------------------
 CHANGES.txt   | 1 +
 bin/cassandra | 7 +++++++
 2 files changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/a14211fb/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 94bea7b..23be338 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 2.0.10
+ * Workaround JVM NPE on JMX bind failure (CASSANDRA-7254)
  * Fix race in FileCacheService RemovalListener (CASSANDRA-7278)
  * Fix inconsistent use of consistencyForCommit that allowed LOCAL_QUORUM
    operations to incorrect become full QUORUM (CASSANDRA-7345)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/a14211fb/bin/cassandra
----------------------------------------------------------------------
diff --git a/bin/cassandra b/bin/cassandra
index c4c2ec2..a950e0b 100755
--- a/bin/cassandra
+++ b/bin/cassandra
@@ -201,6 +201,13 @@ while true; do
     esac
 done
 
+# see CASSANDRA-7254
+"$JAVA" -cp $CLASSPATH $JVM_OPTS 2>&1 | grep -q 'Error: Exception thrown by the agent
: java.lang.NullPointerException'
+if [ $? -ne "1" ]; then 
+    echo Unable to bind JMX, is Cassandra already running?
+    exit 1;
+fi
+
 # Start up the service
 launch_service "$pidfile" "$foreground" "$properties" "$classname"
 


Mime
View raw message