You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by cw...@apache.org on 2011/03/04 22:57:18 UTC
svn commit: r1078165 -
/uima/uima-as/trunk/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/JmsEndpointConnection_impl.java
Author: cwiklik
Date: Fri Mar 4 21:57:18 2011
New Revision: 1078165
URL: http://svn.apache.org/viewvc?rev=1078165&view=rev
Log:
UIMA-2072 improved log message in send() while handling exception
Modified:
uima/uima-as/trunk/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/JmsEndpointConnection_impl.java
Modified: uima/uima-as/trunk/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/JmsEndpointConnection_impl.java
URL: http://svn.apache.org/viewvc/uima/uima-as/trunk/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/JmsEndpointConnection_impl.java?rev=1078165&r1=1078164&r2=1078165&view=diff
==============================================================================
--- uima/uima-as/trunk/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/JmsEndpointConnection_impl.java (original)
+++ uima/uima-as/trunk/uimaj-as-activemq/src/main/java/org/apache/uima/adapter/jms/activemq/JmsEndpointConnection_impl.java Fri Mar 4 21:57:18 2011
@@ -19,6 +19,8 @@
package org.apache.uima.adapter.jms.activemq;
+import java.io.IOException;
+import java.io.InterruptedIOException;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
@@ -593,6 +595,7 @@ public class JmsEndpointConnection_impl
synchronized (producer) {
producer.send(aMessage);
}
+
}
// Starts a timer on a broker connection. Every time a new message
// is sent to a destination managed by the broker the timer is
@@ -608,19 +611,21 @@ public class JmsEndpointConnection_impl
if (UIMAFramework.getLogger(CLASS_NAME).isLoggable(Level.WARNING)) {
String key = "";
+ String endpointName = "";
if ( delegateEndpoint != null ) {
delegateEndpoint.getDelegateKey();
+ endpointName = ((ActiveMQDestination) delegateEndpoint.getDestination())
+ .getPhysicalName();
}
if ( "Client".equals(target) ) {
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.WARNING, CLASS_NAME.getName(),
"send", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,
"UIMAEE_service_delivery_to_client_exception__WARNING",
- new Object[] { controller.getComponentName(), ((ActiveMQDestination) delegateEndpoint.getDestination())
- .getPhysicalName()});
+ new Object[] { controller.getComponentName(),endpointName });
} else {
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.WARNING, CLASS_NAME.getName(),
"send", UIMAEE_Constants.JMS_LOG_RESOURCE_BUNDLE,
- "UIMAEE_service_delivery_exception__WARNING",new Object[] { controller.getComponentName(), key});
+ "UIMAEE_service_delivery_exception__WARNING",new Object[] { controller.getComponentName(), key, endpointName});
}
UIMAFramework.getLogger(CLASS_NAME).logrb(Level.WARNING, CLASS_NAME.getName(),