JMS Trigger usage

Hi,

I want to subscribe message from UM using jms trigger in IS. I want to filter message based on custom property field - PartyID.
What is the syntax used in Message selector of jms trigger to achieve this.
I tried few combinations like %JMSMessage/properties/PartID%==‘qwerty’ but no luck.

Please let me the syntax used in Message selector of jms trigger.

Thanks,
Monica

Hi Monica,

UM triggers use SQL92-like syntax for filters. Also, they act directly on the message properties at server-wide, so you shouldn’t specify that part of the structure as you would for a client-side filter.
So your message selector should be this:

PartID = ‘qwerty’

Hope this helps.

1 Like

Thanks Jonathan.
This helps and I was able to test successfully.

Regards,
Monica

Hi Jonathan,
we are using UM9.8 and IS 9.8. Experiencing major problems with respect to JMS message selector.
When a message is posted in a topic , the JMS message selector present in the trigger is not considered and being by-passed. These filters were working fine in 8.2 and after migration we are facing this issue.

sample message selector which was working in 8.2

(vara= ‘')
AND
(varb= '
’ OR varb= ‘')
AND
(varc= '
’ OR varc= ‘’ OR varc= '’ OR varc= ‘’ OR varc= '’ OR varc= ‘***’)

In 9.8 , this selector is completely ignored and the messages are getting picked up by trigger even though it is not supposed to.
another thing which I find weird when I look in enterprise manager is that the event published is present in all named objects no matter what whereas it should be present only in the named object which matches the right message selector.

Regards,

Dinesh,
I checked your syntax directly using Enterprise Manager (snoop with filter) and it looks OK. I did test it without line breaks in the filter clause.
I suggest you try that: go to EM, open the snoop tab for the topic, paste the filter and then click Start. Then publish messages from IS and see whether they show up in the snoop or not.
I checked with UM 10.2, so if you see something with 9.8, then please open a support ticket.

Regarding messages showing up in the shared durable - that was the default behavior in 9.8. Please check the realm property Global Values > SharedDurableFilterBound. It should be set to TRUE, which ensures that filters are applied at publish-time and messages not matching won’t reach the shared durable.

In any case, make sure you have the latest IS and UM 9.8 fixes installed.

Hope this helps.

HI Jonathan,

The Message Selector works without line gaps. Line gaps were the problem.

I feel this is really weird and unstable.

Thanks,

Did it work with line breaks with Broker?
If so, I’ll have this looked into by the UM team, as we do want to achieve maximum Broker compatibility.

yes with Broker Line breaks always worked.

Dinesh,

I can have this addressed by R&D.
Can you check that the issue exists with a more trivial message selector? E.g.
var1 = ‘1’
AND
var2 = ‘2’
Can you check whether the issue also occurs on 10.2?
What are your timelines for getting this resolved?