You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by or...@apache.org on 2019/08/12 08:29:17 UTC

[qpid-broker-j] branch 7.1.x updated: QPID-8355: [Broker-J] Improve exception handling on instantiation of JMX MBeans

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

orudyy pushed a commit to branch 7.1.x
in repository https://gitbox.apache.org/repos/asf/qpid-broker-j.git


The following commit(s) were added to refs/heads/7.1.x by this push:
     new 8c383f1  QPID-8355: [Broker-J] Improve exception handling on instantiation of JMX MBeans
8c383f1 is described below

commit 8c383f15914cba5de4809174ed51e2df9206cb9f
Author: Alex Rudyy <or...@apache.org>
AuthorDate: Mon Aug 12 09:25:02 2019 +0100

    QPID-8355: [Broker-J] Improve exception handling on instantiation of JMX MBeans
    
    (cherry picked from commit 3caf52ae0bac0a8008434dfb62478e5689d3a499)
---
 .../src/main/java/org/apache/qpid/server/model/AbstractContainer.java   | 2 +-
 .../main/java/org/apache/qpid/server/model/BrokerAttributeInjector.java | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/broker-core/src/main/java/org/apache/qpid/server/model/AbstractContainer.java b/broker-core/src/main/java/org/apache/qpid/server/model/AbstractContainer.java
index 868e933..2114ea8 100644
--- a/broker-core/src/main/java/org/apache/qpid/server/model/AbstractContainer.java
+++ b/broker-core/src/main/java/org/apache/qpid/server/model/AbstractContainer.java
@@ -137,7 +137,7 @@ public abstract class AbstractContainer<X extends AbstractContainer<X>> extends
             String maxDirectMemoryAsString = (String)getValue.invoke(vmOption);
             maxMemory = Long.parseLong(maxDirectMemoryAsString);
         }
-        catch (ClassNotFoundException | NoSuchMethodException | IllegalAccessException e)
+        catch (ClassNotFoundException | NoSuchMethodException | IllegalAccessException | IllegalArgumentException e)
         {
             LOGGER.debug("Cannot determine direct memory max size using com.sun.management.HotSpotDiagnosticMXBean: " + e.getMessage());
         }
diff --git a/broker-core/src/main/java/org/apache/qpid/server/model/BrokerAttributeInjector.java b/broker-core/src/main/java/org/apache/qpid/server/model/BrokerAttributeInjector.java
index 5709c6c..42d108e 100644
--- a/broker-core/src/main/java/org/apache/qpid/server/model/BrokerAttributeInjector.java
+++ b/broker-core/src/main/java/org/apache/qpid/server/model/BrokerAttributeInjector.java
@@ -71,7 +71,7 @@ public class BrokerAttributeInjector implements ConfiguredObjectAttributeInjecto
                     ManagementFactory.getPlatformMXBean((Class<? extends PlatformManagedObject>) hotSpotDiagnosticMXBeanClass);
 
         }
-        catch (ClassNotFoundException e)
+        catch (IllegalArgumentException | ClassNotFoundException e)
         {
             LOGGER.debug("Cannot find com.sun.management.HotSpotDiagnosticMXBean MXBean: " + e);
         }


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