activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From neek <>
Subject Re: AMQ 5.6 breaks Stomp 1.0 clients, was: Re: 5.5 to 5.6 upgrade, stomp client suddenly gets "User name [ xyz] or password is invalid."
Date Wed, 25 Jul 2012 15:39:28 GMT
On 07/25/2012 08:21 PM, dejanb [via ActiveMQ] wrote:
> Can you try the latest snapshot and confirm it works for you

Looks like progress.  My old stomp 1.0 client can connect, login and 
send a message to ActiveMQ 5.7-SNAPSHOT.

Unfortunately it then throws:

      [java] Jul 25, 2012 10:00:59 PM 
org.apache.activemq.transport.stomp.ProtocolConverter handleException
      [java] WARNING: Exception occurred processing:
      [java] SEND
      [java] amq-msg-type:MapMessage
      [java] transformation:jms-map-json
      [java] destination:/queue/integration.account_update
      [java] transformation-error:org/xmlpull/v1/XmlPullParserException
org.apache.activemq.transport.stomp.ProtocolException: Unsupported 
message type 'MapMessage'

I've seen this before and don't think I ever worked a way around it.

To try to get around this, I updated my PHP client to the latest from 
the github repo, and dropped it into my client e-commerce site lib 
directory, and put together a basic test using the 
stomp-php/src/examples/transformation.php as a guide. (the 'namespace', 
'use' and 'auto_loader' stuff is completely foreign to me, and I wasted 
some time trying to get it to work .. the require_once and 
FuseSource\Stomp\Stomp syntax runs, at least)

         ini_set('include_path', ini_get('include_path') . 
PATH_SEPARATOR . 'lib' . PATH_SEPARATOR . 'lib/FuseSource');
         // make a connection to ActiveMQ
         if ($dbg) error_log("Making connection to " . 
         $con = new FuseSource\Stomp\Stomp(ACTIVEMQ_STOMP_URL);
         // connect

         // real data $body = array('map' => array('entry' => $entries));
         $body = array('test' => 'foo', 'othertest' => 1234); // dummy data

         $header = array('transformation' => 'jms-map-json');
         $mapMessage = new FuseSource\Stomp\Message\Map($body, $header);
         if ($dbg) error_log("Calling send...");
         $con->send("/queue/integration.account_update", $mapMessage, 

This caused the server to receive a message, but it's not of type 

      [java] Jul 25, 2012 10:30:29 PM 
ltd.yavin.liveauction.jms.GenericConsumer onMessage
      [java] INFO: XXX message class 
org.apache.activemq.command.ActiveMQTextMessage: ActiveMQTextMessage 
{commandId = 3, responseRequired = false, messageId = 
ID:uberneek-33640-1343230073443-8:3:-1:1:1, originalDestination = null, 
originalTransactionId = null, producerId = 
ID:uberneek-33640-1343230073443-8:3:-1:1, destination = 
queue://integration.account_update, transactionId = null, expiration = 
0, timestamp = 1343230229732, arrival = 0, brokerInTime = 1343230229732, 
brokerOutTime = 1343230229733, correlationId = null, replyTo = null, 
persistent = false, type = null, priority = 4, groupID = null, 
groupSequence = 0, targetConsumerId = null, compressed = false, userID = 
null, content = null, marshalledProperties = null, dataStructure = null, 
redeliveryCounter = 0, size = 1059, properties = 
transformation=jms-map-json}, readOnlyProperties = true, readOnlyBody = 
true, droppable = false, text = {"test":"foo","othertest":1234}}

My server then rejects the message, because it's coded to only accept 
MapMessage objects.

I can see the conversation going over the wire via wireshark:






Assuming I'm going to stick with the new client and use Stomp 1.1, can 
you suggest why the message being sent isn't recognised as a MapMessage 
on the server side?

I'm sure part of the point here was to show that 5.7-SNAPSHOT can 
communicate with the old 1.0 Stomp client.  This failed for me but I'm 
not sure if you want me to do further debugging, as it failed within the 
activemq code and I presume you can reproduce that error on your system 
and debug far better than I can.


View this message in context:
Sent from the ActiveMQ - User mailing list archive at
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message