When attempting to send an XML message, Hermes is adding spaces in front of the XML message. It shouldn't be doing that. There is an additional space after the </JMS> tag and the start of the message.
Can you explain how you do the upload? Is the XML from a file, do you use the message creation dialog and paste it in? Which exact buttons do you click?
I've just tested with some XML in a file and I don't get any additional spaces. When just uploading a file the contents is not relevant, its just treated as text.
Colin Crist [09/Jan/12 03:29 AM]
Can you explain how you do the upload? Is the XML from a file, do you use the message creation dialog and paste it in? Which exact buttons do you click?
I've just tested with some XML in a file and I don't get any additional spaces. When just uploading a file the contents is not relevant, its just treated as text.
What is the jms tag you mention?
Hey man, I figured out the issue... It was an encoding issue. When I right clicked on a queue which was defined, I selected a new message and I then either copy & pasted or inserted the xml from the file. In both cases I got the same error message. I ended up writing my own MQ client in Java and when I compared the JMS header I realized the only difference was the encoding. I guess by default the message is encoded in UTF-8 which writes\removes on read the additional characters in front of the message. However, my MQ listener is a vendor application which can only handle messages if they are encoded using ISO-8859-1.
I figured out the problem but how do you change the encoding being used by HermesJMS ?
Chris [12/Jan/12 01:24 PM]
Hey man, I figured out the issue... It was an encoding issue. When I right clicked on a queue which was defined, I selected a new message and I then either copy & pasted or inserted the xml from the file. In both cases I got the same error message. I ended up writing my own MQ client in Java and when I compared the JMS header I realized the only difference was the encoding. I guess by default the message is encoded in UTF-8 which writes\removes on read the additional characters in front of the message. However, my MQ listener is a vendor application which can only handle messages if they are encoded using ISO-8859-1.
I figured out the problem but how do you change the encoding being used by HermesJMS ?
Colin Crist [06/Jul/12 05:56 AM]
You can now set the character set to use when you insert a file when creating a TextMessage in the Send Message... dialog.
I've just tested with some XML in a file and I don't get any additional spaces. When just uploading a file the contents is not relevant, its just treated as text.
What is the jms tag you mention?