Adding JMS or MQ/JMS Custom Header Attributes

If you need to add a custom header to your JMS (default messaging) or MQ/JMS message in WebSphere , you have two options. You can specify it as a custom header on the import component in the assembly diagram, or you can use a Medation Module.

You can add the custom header property in the assembly diagram by: Clicking the MQ/JMS Import Component. Click the Method binding in the propreties view. Scroll to the Custom Header table and add the name/value pair. It should be noted that you can only do this for static values. If you need to assign the value of your custom property based on the data from your Business Object, you MUST use a Mediation Flow. Sadly, the ‘Value’ column is not an XPATH expression like it should be.

To do this in a mediation module, you do your normal modification of the /header, nothing special.

Related Posts


You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

AddThis Social Bookmark Button

2 Responses to “Adding JMS or MQ/JMS Custom Header Attributes”

  1. Bernard Stibbe Says:

    Dan,

    Can you add Custom Headers in Soap over JMS ?
    If so, where can I find an example about this.

    I like to use it, to filter out published messages, post to a topic?

    Regards,

    Bernard

  2. Hi Bernard,

    In my humblest of humble opinions, SOAP/JMS support is flaky at best and you’d be far better off staying away from it and using JMS Text messages.

Leave a Reply