activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Albert Strasheim (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AMQCPP-35) Stomp content-length header not being set on BytesMessage
Date Mon, 25 Dec 2006 00:51:02 GMT
    [ https://issues.apache.org/activemq/browse/AMQCPP-35?page=comments#action_37766 ] 
            
Albert Strasheim commented on AMQCPP-35:
----------------------------------------

Doing this after the writeString:

bytesMessage->setBodyBytes(bytesMessage->getBodyBytes(), bytesMessage->getBodyLength());

causes the message to come out as a BytesMessage on the receiving end.

> Stomp content-length header not being set on BytesMessage
> ---------------------------------------------------------
>
>                 Key: AMQCPP-35
>                 URL: https://issues.apache.org/activemq/browse/AMQCPP-35
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>          Components: Stomp
>    Affects Versions: 1.1
>            Reporter: Albert Strasheim
>         Assigned To: Nathan Mittler
>
> Not sure if this is a bug or if I'm just doing something wrong, but here goes.
> On a cms::Session I'm calling createBytesMessage and getting back a cms::BytesMessage
which is an activemq::connector::stomp::commands::BytesMessageCommand underneath. On this
message I set an int property and write a string using writeString. Then I send the message
to my producer. At no point does it seem as if the content-length header is set in this case.
I verified by checking the properties written out for this message in StompCommandWriter::writeCommand.
Due to the absence of this header, when AMQCPP receives this message, it assumes it is a TextMessageCommand
instead of a BytesMessageCommand.
> The only way the header can get set is by something calling setBytes on the BytesMessageCommand
which calls through to setBytes of AbstractCommand which sets the header. I don't think this
happens when one only does a writeString.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message