Hi,
There are 3 ways to accomplish this:
1. Via Xbean Spring dependency injection:
<connectionFactory brokerURL="vm://localhost"
xmlns="http://activemq.org/config/1.0">
<redeliveryPolicy>
<redeliveryPolicy maximumRedeliveries="20"/>
</redeliveryPolicy>
</connectionFactory>
2. Via broker URL:
ActiveMQConnectionFactory cf = new
ActiveMQConnectionFactory("vm://localhost?jms.redeliveryPolicy.maximumRedeliveries=3434");
3. Via POJO:
ActiveMQConnectionFactory cf = new ActiveMQConnectionFactory();
cf.getRedeliveryPolicy().setMaximumRedeliveries(3434);
tobinibot wrote:
I'm sorry if this is a stupid question, but I've spent all morning looking,
and I haven't been able to find it yet.
I'd like to configure the redelivery options. I found the activemq.xsd
schema file that defines the redeliveryPolicy element (and associated
complex type). I believe that element is exactly what I'm looking for.
However, I can't figure out where to put it. The only config file I've been
able to find is my $ACTIVEMQ_DIR/conf/activemq.xml, which does not look it
follows that schema. Plus, the redeliveryPolicy element is supposed to go
in a connectionFactory element, and my activemq.xml does not have any of
those.
Again, I'm sorry if this is a really basic question, but it's stumped me all
morning. Thanks.
Tobin