Activemq wildcard support in spring xd jms source?

289 views Asked by At

I', using activemq 5.9 with spring xd 1.1. I want to subscribe activemq topic. So, I'm using jms source. Activemq supports wildcards like * , >. > is used to recursively match any destination starting from this name I'm trying to use this wildcard while subscribing jms source like this :
stream create --name streamname --definition "jms --clientId=1 --destination=springin.> --durableSubscription=true --pubSub=true --subscriptionName=streamName | null"

Error : Command failed org.springframework.xd.rest.client.impl.SpringXDException: XD133E:(pos 42): Expected channel prefix of 'queue' or 'topic' but found '--' jms --clientId=1 --destination=springin.> --durableSubscription=true --pubSub=true --subscriptionName=streamName | null

But when i'm trying something like this :
stream create --name streamname --definition "jms --clientId=3 --destination=springin.*.tp1 --durableSubscription=true --pubSub=true --subscriptionName=streamName | null"
the stream is getting created.

So '*' is supported but '>' is not working. I want to use this '>' wildcard. Is there any workaround for this?

1

There are 1 answers

0
Gary Russell On BEST ANSWER

> is a reserved character in the DSL (for routing to named channels).

Put the value in (escaped) quotes: --destination=\"springin.>\".