activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dej...@apache.org
Subject svn commit: r965897 - in /activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp: LegacyFrameTranslator.java ProtocolConverter.java
Date Tue, 20 Jul 2010 16:25:52 GMT
Author: dejanb
Date: Tue Jul 20 16:25:52 2010
New Revision: 965897

URL: http://svn.apache.org/viewvc?rev=965897&view=rev
Log:
https://issues.apache.org/activemq/browse/AMQ-2841 - log stomp protocol errors

Modified:
    activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/LegacyFrameTranslator.java
    activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/ProtocolConverter.java

Modified: activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/LegacyFrameTranslator.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/LegacyFrameTranslator.java?rev=965897&r1=965896&r2=965897&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/LegacyFrameTranslator.java
(original)
+++ activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/LegacyFrameTranslator.java
Tue Jul 20 16:25:52 2010
@@ -161,7 +161,7 @@ public class LegacyFrameTranslator imple
             return converter.createTempTopic(name);
         } else {
             throw new ProtocolException("Illegal destination name: [" + name + "] -- ActiveMQ
STOMP destinations "
-                                        + "must begine with one of: /queue/ /topic/ /temp-queue/
/temp-topic/");
+                                        + "must begin with one of: /queue/ /topic/ /temp-queue/
/temp-topic/");
         }
     }
 

Modified: activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/ProtocolConverter.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/ProtocolConverter.java?rev=965897&r1=965896&r2=965897&view=diff
==============================================================================
--- activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/ProtocolConverter.java
(original)
+++ activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/ProtocolConverter.java
Tue Jul 20 16:25:52 2010
@@ -60,6 +60,8 @@ import org.apache.activemq.util.IOExcept
 import org.apache.activemq.util.IdGenerator;
 import org.apache.activemq.util.IntrospectionSupport;
 import org.apache.activemq.util.LongSequenceGenerator;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 import org.springframework.context.ApplicationContextAware;
 
 /**
@@ -67,6 +69,8 @@ import org.springframework.context.Appli
  */
 public class ProtocolConverter {
 
+    private static final Log LOG = LogFactory.getLog(ProtocolConverter.class);
+    
     private static final IdGenerator CONNECTION_ID_GENERATOR = new IdGenerator();
 
     private final ConnectionId connectionId = new ConnectionId(CONNECTION_ID_GENERATOR.generateId());
@@ -202,6 +206,7 @@ public class ProtocolConverter {
     }
 
     protected void handleException(Throwable exception, StompFrame command) throws IOException
{
+        LOG.warn("Exception occured processing: \n" + command, exception);
         // Let the stomp client know about any protocol errors.
         ByteArrayOutputStream baos = new ByteArrayOutputStream();
         PrintWriter stream = new PrintWriter(new OutputStreamWriter(baos, "UTF-8"));



Mime
View raw message