-
1. Re: configure delayed redelivery using core API?
clebert.suconic Nov 19, 2012 3:55 PM (in response to pjrhalicky)1 of 1 people found this helpfulYou just do this on the address settings for the queues matching your names...
<address-settings>
<!--override the redelivery-delay for the example queue-->
<address-setting match="jms.queue.exampleQueue">
<redelivery-delay>5000</redelivery-delay>
</address-setting>
</address-settings>
On the case if you don't have jms address, just use just the name for your queue, or look on the matching arguments... you can have something like
<address-settings>
<!--override the redelivery-delay for the example queue-->
<address-setting match="#">
<redelivery-delay>5000</redelivery-delay>
</address-setting>
</address-settings>
-
2. Re: configure delayed redelivery using core API?
pjrhalicky Nov 19, 2012 4:30 PM (in response to clebert.suconic)OK would this work to set 5 seconds redelivery delay on all queues in the system? (in other words, will the "#" match all queues?)
Map<String, AddressSettings> adrsettings = new HashMap<String, AddressSettings>();
AddressSettings as = new AddressSettings();
as.setRedeliveryDelay(5000);
adrsettings.put("#", as);
configuration.setAddressesSettings(adrsettings);
// start the HornetQ server
server = HornetQServers.newHornetQServer(configuration);
-
3. Re: configure delayed redelivery using core API?
clebert.suconic Nov 19, 2012 6:31 PM (in response to pjrhalicky)Yes.. it should work...
notice that redelivery means the current message, all subsequent messages will still be dleivered after this failure. and the redelivered message will be back to the queue in 5 seconds after a redelivery.
-
4. Re: configure delayed redelivery using core API?
pjrhalicky Nov 20, 2012 1:54 AM (in response to clebert.suconic)Thank you, I'll test this a bit later and will report back if there's a problem.