activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Doug Clark <dcl...@ea.com>
Subject Re: [jira] Created: (AMQ-659) Text message format is incompatible between activemq and openwire .NET
Date Fri, 18 Aug 2006 18:35:01 GMT

I'm having trouble interpreting this post, and the linked bug.  Has this been
fixed in the OpenWire .NET client?  If so, how do I get the fix?  I'm using
the OpenWire .NET client code I downloaded from here:

svn co
http://svn.apache.org/repos/asf/incubator/activemq/trunk/activemq-dotnet/

And what I believe is ActiveMQ 4.0.1.  I run the consumer example, and get
the following output:

C:\Documents and Settings\dclark\Desktop\My
Stuff\tools\ActiveMQ\incubator-activemq-4.0.1\example>ant consumer
Buildfile: build.xml

init:

compile:

consumer:
     [echo] Running consumer against server at $url = tcp://localhost:61616
for subject $subject = TEST.FOO
     [java] Connecting to URL: tcp://localhost:61616
     [java] Consuming queue: TEST.FOO
     [java] Using non-durable subscription
     [java] We are about to wait until we consume: 10 message(s) then we
will shutdown
     [java] ---- well, we got this far... ----
     [java] ---- message.toString: ActiveMQTextMessage {commandId = 5,
responseRequired = true, messageId = ae38d0ea-6db
a-4488-80b1-8cbd9f383fe6:1:1:1, originalDestination = null,
originalTransactionId = null, producerId = ae38d0ea-6dba-448
8-80b1-8cbd9f383fe6:1:1, destination = queue://TEST.FOO, transactionId =
null, expiration = 0, timestamp = 0, arrival =
0, correlationId = abc, replyTo = null, persistent = false, type = null,
priority = 0, groupID = null, groupSequence = 0
, targetConsumerId = null, compressed = false, userID = null, content =
org.apache.activeio.packet.ByteSequence@13bd574,
 marshalledProperties = org.apache.activeio.packet.ByteSequence@13adc56,
dataStructure = null, redeliveryCounter = 1, si
ze = 0, properties = null, readOnlyProperties = true, readOnlyBody = true,
text = null}
     [java] Exception in thread "main" java.lang.OutOfMemoryError: Requested
array size exceeds VM limit
     [java] ---- casting message to TextMessage message

My client app does this:

        private void button1_Click(object sender, EventArgs e)
        {
            IConnectionFactory factory = new ConnectionFactory(new
Uri(hosttextBox.Text));
            using (IConnection connection = factory.CreateConnection())
            {
                ISession session = connection.CreateSession();
                IDestination destination =
session.GetQueue(queuetextBox.Text);

                // lets create a producer
                IMessageProducer producer =
session.CreateProducer(destination);
                producer.Persistent = true;

                // lets send a message
                ITextMessage request = session.CreateTextMessage("Hello
World!");
                request.NMSCorrelationID = "abc";
                request.Properties["JMSXGroupID"] = "cheese";
                request.Properties["myHeader"] = "James";

                producer.Send(request);
            }
        }

Am I doing something wrong, or is this still a bug?



JIRA jira@activemq.org wrote:
> 
> Text message format is incompatible between activemq and openwire .NET
> ----------------------------------------------------------------------
> 
>          Key: AMQ-659
>          URL: http://jira.activemq.org/jira//browse/AMQ-659
>      Project: ActiveMQ
>         Type: Bug
> 
>   Components: Broker  
>     Versions: 4.0    
>  Environment: - ActiveMQ Snapshot from 06-April
> - Openwire .NET revision 392254 (Used on framework 1.1)
> - Solaris 10 for activemq broker
>     Reporter: Laurent Jeanneau
> 
> 
> The class MarshallingSupport (from org.apache.activemq.util) is
> unmarshalling / marshalling UTF8 strings containing the length coded as an
> integer at the beginning of the stream.
> 
> Unfortunately the strings marshalled by openwire do not contain any length
> at the beginning. Decoding these strings result in a
> java.lang.OutOfMemoryError: Java heap space in activemq (the first 4 bytes
> of the string are interpreted as a length resulting in a buffer overflow)
> 
> -- 
> This message is automatically generated by JIRA.
> -
> If you think it was sent incorrectly contact one of the administrators:
>    http://jira.activemq.org/jira//secure/Administrators.jspa
> -
> For more information on JIRA, see:
>    http://www.atlassian.com/software/jira
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/-jira--Created%3A-%28AMQ-659%29-Text-message-format-is-incompatible-between-activemq-and-openwire-.NET-tf1412109.html#a5875223
Sent from the ActiveMQ - Dev forum at Nabble.com.


Mime
View raw message