Apache Tuscany 1.6 How do you set the JMS Binding Delivery Mode to NON_PERSISTENT?
Posted
by Robert Greiner
on Stack Overflow
See other posts from Stack Overflow
or by Robert Greiner
Published on 2010-03-15T21:36:16Z
Indexed on
2010/03/15
21:39 UTC
Read the original article
Hit count: 321
I am using Tuscany 1.6 and am trying to set the Delivery Mode JMS Binding to NON_PERSISTENT.
I've tried using uri="jms:MyService?deliveryMode=1"
(which is what the spec (PDF) says to do)
but, I ended up getting the following exception:
Unknown token deliveryMode=1
I also tried <headers JMSDeliveryMode="NON_PERSISTENT"/>
, although I did not
get an exception the messages still got delivered as PERSISTENT.
This is the format for the URI
jms:<jms-dest>?
connectionFactoryName=<Connection-Factory-Name> &
destinationType={queue|topic}
deliveryMode=<Delivery-Mode> &
timeToLive=<Time-To-Live> &
priority=<Priority> &
<User-Property>=<User-Property-Value> & …
This is the example I am using
<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" name="MyValueComposite">
<service name="MyValueService">
<interface.java interface="services.myvalue.MyValueService"/>
<binding.jms uri="jms:MyValueServiceQueue?activationSpecName=MyValueServiceAS&... "/>
</service>
<reference name="StockQuoteService">
<interface.java interface="services.stockquote.StockQuoteService"/>
<binding.jms uri="jms:StockQuoteServiceQueue?connectionFactoryName=StockQuoteServiceQCF&deliveryMode=1&... "/>
</reference>
</composite>
© Stack Overflow or respective owner