Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
Description
The client converts the byte[] passed in to javax.jms.Message#setJMSCorrelationIDAsBytes to a String via new String(bytes);.
If the bytes are not the encoding of a String in the current default encoding (in which case why would you use this method in the first place), this is wrong.
In the JMS API implementation of setJMSCorrelationIDAsBytes()/getJMSCorrelationIDAsBytes() is optional and it explicitly allows the provider to throw java.lang.UnsupportedOperationException.
We should either pack the raw bytes into the AMQShortString or throw UnsupportedOperationException.
Attachments
Issue Links
- relates to
-
QPID-7897 [Java 0-8...0-9-1 Client] Message#getJMSCorrelationIDAsBytes() erroneously first converts to string before retreiving bytes
- Closed