camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vguna <gr...@gmx.de>
Subject Re: spring DeadLetterChannel redelivery config
Date Fri, 04 Jul 2008 12:52:58 GMT

Hi.

Here's the same problem with this configuration:

    	<route>
    		<from uri="activemq:NEW" />
    	    <onException>   	         
    	        <redeliveryPolicy>
    	            <maximumRedeliveries>4</maximumRedeliveries>    	           

    	            <initialRedeliveryDelay>30000</initialRedeliveryDelay>
    	            <useExponentialBackOff>true</useExponentialBackOff>   	     
      
    	        </redeliveryPolicy>
    	    </onException>
    	</route>

It just happens nothing when an exception on the onMessage method is thrown.
Means: 5 retries in a delay of 1 second, after that it will be put in the
DLQ.

Maybe spring configuration is broken? Didn't try the DSL yet. Don't want to
code anything for this configuration settings.

Any hints?
Veit



Marc Giger wrote:
> 
> Hi,
> 
> I'm trying to configure the DeadLetterChannel with spring.
> Unfortunately without success. No matter where I declare the
> <onException>, camel tries to redeliver the message 5 times in the case
> of an exception.
> 
> How must the following configuration be modified so that camel just
> tries to deliver once?
> 
> <camelContext id="camel"
> xmlns="http://activemq.apache.org/camel/schema/spring">
> <route> 
>             <from uri="cxf:bean:routerEndpoint"/>
>             <onException> <!-- no effect -->
>                 <redeliveryPolicy>
>                     <maximumRedeliveries>0</maximumRedeliveries>
>                 </redeliveryPolicy>
>             </onException>
>             <process ref="decryptProcessor">
>                 <onException> <!-- no effect -->
>                     <redeliveryPolicy>
>                         <maximumRedeliveries>0</maximumRedeliveries>
>                     </redeliveryPolicy>
>                 </onException>
>             </process>
>             <choice>
>                 <when>
>                     <methodCall bean="endpointSelector"
> method="matches"/> <to
> uri="cxf:bean:serviceEndpoint?dataFormat=MESSAGE"/> </when>
>                 <otherwise>
>                     <to
> uri="cxf:bean:localEndpoint"/> </otherwise>
>             </choice>            
>         </route>
>     </camelContext>
> 
> Thanks a lot!
> 
> Cheers,
> 
> Marc
> 
> 

-- 
View this message in context: http://www.nabble.com/spring-DeadLetterChannel-redelivery-config-tp15906561s22882p18278925.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message