-
Aug 5th, 2011, 11:57 AM
#1
how to add additional headers to outbound jms message
I have the following scenario:
- receive a message on a jms topic
- add a custom header
- send it out on a different jms topic
How can I add the customer header. do I need to provide a custom implementation of header-mapper? If so, are there any example implementations I can follow?
-
Aug 15th, 2011, 06:15 PM
#2
The JmsTemplate lets you create a Message, which is what you want to send a message. From there, you can add some of the standardized header fields, or add properties (e.g. setStringProperty) to create something that looks and behaves as a custom header. AFAIK, custom headers would be proprietary extensions to the JMS API.
-
Aug 17th, 2011, 08:52 AM
#3
Used header enricher
Thank you for your response. I was able to use header-enricher to add the custom header. I believe the implementation gets the map of header key value pairs and adds the custom headers to it.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules