activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject git commit: AMQ-4748: Fixed shutting down AMQ standalone does not raise exception.
Date Wed, 02 Oct 2013 09:55:00 GMT
Updated Branches:
  refs/heads/trunk 4a01e40cb -> e0f2dc9bd


AMQ-4748: Fixed shutting down AMQ standalone does not raise exception.


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

Branch: refs/heads/trunk
Commit: e0f2dc9bd45012f2ba98287f4a5671713c582751
Parents: 4a01e40
Author: Claus Ibsen <claus.ibsen@gmail.com>
Authored: Wed Oct 2 11:54:53 2013 +0200
Committer: Claus Ibsen <claus.ibsen@gmail.com>
Committed: Wed Oct 2 11:54:53 2013 +0200

----------------------------------------------------------------------
 .../org/apache/activemq/console/command/StartCommand.java     | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/activemq/blob/e0f2dc9b/activemq-console/src/main/java/org/apache/activemq/console/command/StartCommand.java
----------------------------------------------------------------------
diff --git a/activemq-console/src/main/java/org/apache/activemq/console/command/StartCommand.java
b/activemq-console/src/main/java/org/apache/activemq/console/command/StartCommand.java
index e2b5768..be3ffc3 100644
--- a/activemq-console/src/main/java/org/apache/activemq/console/command/StartCommand.java
+++ b/activemq-console/src/main/java/org/apache/activemq/console/command/StartCommand.java
@@ -116,7 +116,12 @@ public class StartCommand extends AbstractCommand {
 
             // The broker has stopped..
             shutdownLatch.await();
-            Runtime.getRuntime().removeShutdownHook(jvmShutdownHook);
+            try {
+                Runtime.getRuntime().removeShutdownHook(jvmShutdownHook);
+            } catch (Throwable e) {
+                // may already be shutdown in progress so ignore
+            }
+
             if( !broker.isRestartRequested() ) {
                 break;
             }


Mime
View raw message