activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "s.csaba" <>
Subject Redeliverypolicy per detination in Spring
Date Mon, 10 Aug 2015 11:16:11 GMT
ActiveMQ 5.11.1
Spring 4.1.1

I'd like to configure redelivery policy per destination in spring xml. (Two
queue with defferent policy.) The RedeliveryPolicyMap setEntries method 
seems to right for this. The javadoc says: "A helper method to allow the
destination map to be populated from a dependency injection framework such
as Spring"

But there is no getter metthod, so the spring framwork throw the following
error message:
"Caused by: org.springframework.beans.NotWritablePropertyException: Invalid
property 'entries' of bean class
[]: Bean
property 'entries' is not writable or has an invalid setter method. Does the
parameter type of the setter match the return type of the getter?"

The missing of RedeliveryPolicyMap.getEntries method is intentional or is a
bug? Can I configure this some other way?

spring configuration:
<bean id="smsOut" class="org.apache.activemq.command.ActiveMQQueue">
	<constructor-arg index="0" value="sms_out" />
<bean id="smsIn" class="org.apache.activemq.command.ActiveMQQueue">
	<constructor-arg index="0" value="sms_in" />
<bean id="smsOutRedeliveryPolicy"
    <property name="destination" ref="smsOut" />
    <property name="maximumRedeliveries" value="10" />
<bean id="smsInRedeliveryPolicy"
    <property name="destination" ref="smsIn" />
    <property name="maximumRedeliveries" value="1" />
<bean id="redeliveryPolicyMap"
	<property name="entries">
			<ref bean="smsOutRedeliveryPolicy" />
			<ref bean="smsInRedeliveryPolicy" />
<bean id="amqConnectionFactory"
    <constructor-arg index="0" value="tcp://localhost:61616" />
    <property name="redeliveryPolicyMap" ref="redeliveryPolicyMap"/>
<bean id="connectionFactory"
    <constructor-arg ref="amqConnectionFactory" />

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message