I tested this approach now and I can create a property that is set with a value. That’s good.
However I need to set the JMSType (due to processing setup) and this is, when reading from the JMS UM queue, placed under JMSMessage/header. I am not able to set this as a property, then nothing happens. And no value is passed to the header JMSType.
I didn’t notice at first that you are setting “JMSType” header.
Actually some of the standard JMS properties/headers are not allowed to set. This details are provided in the API Gateway user guide. Please refer Policies → Routing → JMS/AMQP Policies → JMS/AMQP Properties → Predefined JMS Properties in the guide.
Setting properties with other key names than JMSType works with JMS as well when using Custom HTTP Header.
But I see your key is named Type and not JMSType, which does not seem to work for JMS.
We use a workaround, calling an IS-service which puts the message on the queue with modified JMSType.
Unfortunately we need this naming of the key to be JMSType.
We too set JMSType using Custom HTTP Header. It went into the queue successfully. But only on the ActiveMQ admin page it is displayed as Type for that message. Not sure with UM.