On 11 September 2014 12:07, Gordon Sim <[email protected]> wrote: > On 09/10/2014 08:02 PM, Rob Godfrey wrote: > >> If you want to use HTTP / MIME style (which I think is better for >> pretty much everything except for maybe a few cases) then just stick >> your message body data in a data section. Only where there is some >> specific advantage to be gained over the HTTP / MIME encoding style >> would I consider using the AMQP type system for your message data. >> > > It was recently pointed out that sending a message as a data section with > a content type of 'text/plain' was interpreted by the 1.0 JMS client as a > ByteMessage. To have the message received as a TextMessage, it had to be > sent as a string-typed amqp-value section. > > I don't know if the JMS mapping already mentions this, but this case would > probably be worth considering there. > > It does. For receiving messsages with data sections it current says:
'application/octet-stream' would be a BytesMessage 'application/x-java-serialized-object' would be an ObjectMessage 'text/plain' would be a TextMessage. There are currently TODOs for charset in the content type, and whether we should do a similar thing to text/plain with any other specific content types that might be represented as a Java String Robbie
