geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r677815 - in /geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager: helper/JMSMessageHelper.java wizard/ListScreenHandler.java
Date Fri, 18 Jul 2008 04:07:11 GMT
Author: gawor
Date: Thu Jul 17 21:07:10 2008
New Revision: 677815

URL: http://svn.apache.org/viewvc?rev=677815&view=rev
Log:
use queueName as PhysicalName if PhysicalName is undefined

Modified:
    geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/helper/JMSMessageHelper.java
    geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/wizard/ListScreenHandler.java

Modified: geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/helper/JMSMessageHelper.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/helper/JMSMessageHelper.java?rev=677815&r1=677814&r2=677815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/helper/JMSMessageHelper.java
(original)
+++ geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/helper/JMSMessageHelper.java
Thu Jul 17 21:07:10 2008
@@ -48,6 +48,7 @@
 import org.apache.geronimo.console.util.PortletManager;
 import org.apache.geronimo.gbean.AbstractName;
 import org.apache.geronimo.gbean.GBeanInfo;
+import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
 import org.apache.geronimo.kernel.Kernel;
 import org.apache.geronimo.kernel.KernelRegistry;
 import org.apache.geronimo.kernel.proxy.GeronimoManagedBean;
@@ -256,7 +257,14 @@
                     for (int j = 0; j < admins.length; j++) {
                         GeronimoManagedBean bean = (GeronimoManagedBean) admins[j];
                         ObjectName name = ObjectName.getInstance(bean.getObjectName());
-                        String physicalNameTemp = (String) admins[j].getConfigProperty("PhysicalName");
+                        String queueName = name.getKeyProperty(NameFactory.J2EE_NAME);
+                        String physicalNameTemp = null;
+                        try {
+                            physicalNameTemp = (String) admins[j].getConfigProperty("PhysicalName");
+                        } catch (Exception e) {
+                            log.warn("PhysicalName undefined, using queueName as PhysicalName");
+                            physicalNameTemp = queueName;
+                        }
                         if (physicalName != null && physicalName.equals(physicalNameTemp))
{
                             AbstractName absName = kernel.getAbstractNameFor(bean);
                             dest = (Destination) kernel.invoke(absName, "$getResource");

Modified: geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/wizard/ListScreenHandler.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/wizard/ListScreenHandler.java?rev=677815&r1=677814&r2=677815&view=diff
==============================================================================
--- geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/wizard/ListScreenHandler.java
(original)
+++ geronimo/server/trunk/plugins/activemq/activemq-portlets/src/main/java/org/apache/geronimo/console/jmsmanager/wizard/ListScreenHandler.java
Thu Jul 17 21:07:10 2008
@@ -183,7 +183,7 @@
                     try {
                         physicalName = (String) admins[j].getConfigProperty("PhysicalName");
                     } catch (Exception e) {
-                        log.warn("PhysicalName undefined, using queueName as PhysicalName",
e);
+                        log.warn("PhysicalName undefined, using queueName as PhysicalName");
                         physicalName = queueName;
                     }
                     String destType = admins[j].getAdminObjectInterface().indexOf("Queue")
> -1 ? "Queue" : "Topic";



Mime
View raw message