camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen" ...@silverbullet.dk>
Subject RE: Camel 1.3 - how to overwrite redeliveryPolicy via Spring XML
Date Thu, 06 Nov 2008 10:14:38 GMT
Hi

I am sorry but there probably is an issue in Camel 1.3. You could temporary try upgrading
to 1.4.0 or 1.5.0 to see if that really fixes the issue. Then you are rest assured that when
you upgrade it will be fixed.



Med venlig hilsen
 
Claus Ibsen
......................................
Silverbullet
Skovsgårdsvænget 21
8362 Hørning
Tlf. +45 2962 7576
Web: www.silverbullet.dk

-----Original Message-----
From: 0xygen08 [mailto:gabiy2k8@yahoo.com] 
Sent: 3. november 2008 20:35
To: camel-user@activemq.apache.org
Subject: RE: Camel 1.3 - how to overwrite redeliveryPolicy via Spring XML


Thanks for the quick response.  onException doesn't seem to catch the
exception. Am I missing something?

I would like to reset the maximumRedeliveries on ANY exception for this
route, so
I've also tried to remove the  <exception> filtering from the configuration
as follows:
  
            <onException>
	        <redeliveryPolicy>
	            <maximumRedeliveries>2</maximumRedeliveries>
	        </redeliveryPolicy>
              <to uri="log:MySpecialLogger"/>
	    </onException>      

but it does not work either.

Thanks again for the input.

---------------

Claus Ibsen wrote:
> 
> Hi
> 
> There have been some refinements in this in the later releases. But as I
> recall it was because the max redelivery counter was off by one is some
> situations.
> 
> Are you sure the onException catches your exception? You could try setting
> a special destination so you are sure its using the onException. Eg that
> it logs the exception with MySpecialLogger
> 
> 	    <onException>
> 	        <exception>
> 	             java.lang.Exception
> 		</exception>
> 	        <redeliveryPolicy>
> 	            <maximumRedeliveries>2</maximumRedeliveries>
> 	        </redeliveryPolicy>
>               <to uri="log:MySpecialLogger"/>
> 	    </onException>             
> 
> 
> 
> Med venlig hilsen
>  
> Claus Ibsen
> ......................................
> Silverbullet
> Skovsgårdsvænget 21
> 8362 Hørning
> Tlf. +45 2962 7576
> Web: www.silverbullet.dk
> -----Original Message-----
> From: 0xygen08 [mailto:gabiy2k8@yahoo.com] 
> Sent: 31. oktober 2008 22:38
> To: camel-user@activemq.apache.org
> Subject: Camel 1.3 - how to overwrite redeliveryPolicy via Spring XML
> 
> 
> Hi,
> I am using Camel 1.3, and try to overwrite the default redeliveryPolicy on
> one of the route.
> I tried with the following spring configuration, and I didn't have problem
> starting 
> application, but the maximumRedeliveries was still using default value 5.
> 
> Is it possible to do that in Camel 1.3 (I can't upgrade to 1.4/1.5 just
> yet)? 
> Thanks,
> -O
> 
> <camelContext id="mycontext" autowireRouteBuilders="false"
>             xmlns="http://activemq.apache.org/camel/schema/spring">
>            
>         <route>
>             <from uri="my:src"/>
> 	    <onException>
> 	        <exception>
> 	             java.lang.Exception
> 		</exception>
> 	        <redeliveryPolicy>
> 	            <maximumRedeliveries>2</maximumRedeliveries>
> 	        </redeliveryPolicy>
> 	    </onException>             
>          
>             <to uri="md:x.queue"/>
>             <to uri="bean:xxr"/>
>             	          
>         </route> 
>     </camelContext>
> -- 
> View this message in context:
> http://www.nabble.com/Camel-1.3---how-to-overwrite-redeliveryPolicy-via-Spring-XML-tp20274414s22882p20274414.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Camel-1.3---how-to-overwrite-redeliveryPolicy-via-Spring-XML-tp20274414s22882p20309146.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message