You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by atg roxx <at...@gmail.com> on 2012/01/28 23:32:56 UTC

errroHandler is not redelivering

Hi,


I am new to camel world.


I read on the camel site that we can use the below configuration to
configure the route.

 But the following this not taking affect. Is the some other setting
which has to done somewhere ??


kindly guide me .

errorHandler(deadLetterChannel("jms:queue:dead")
    .maximumRedeliveries(3).redeliveryDelay(5000));



--cheers,

atgroxx

Re: errroHandler is not redelivering

Posted by Babak Vahdat <ba...@swissonline.ch>.
Am 30.01.2012 um 17:48 schrieb atg roxx <at...@gmail.com>:

> Hi Babak,
> 
> 
> I cant provide the logs in debug mode but assure you that
> SoapFaultClientException  is getting generated.
> 

But that makes it difficult for me to help however maybe others on the forum have got an idea about this behaviour.

Babak

> and yes ----
> 
> <bean id="jms"
> class="org.apache.activemq.camel.component.*ActiveMQComponent*">
> -------------
> 
> the above is the copy paste issue;
> 
> 
> 
> On Mon, Jan 30, 2012 at 3:30 PM, Babak Vahdat
> <ba...@swissonline.ch>wrote:
> 
>> Hi
>> 
>> Can you turn the log level to DEBUG and send it *including* the place
>> where,
>> as you said, you make sure that a SoapFaultClientException is thrown?
>> 
>> BTW I see STARS around your "ActiveMQComponent" spring bean declaration of
>> yours:
>> 
>> <bean id="jms"
>> class="org.apache.activemq.camel.component.*ActiveMQComponent*">
>> 
>> Is that just as Copy & Paste issue?
>> 
>> Babak
>> 
>> --
>> View this message in context:
>> http://camel.465427.n5.nabble.com/errroHandler-is-not-redelivering-tp5438700p5441739.html
>> Sent from the Camel - Users mailing list archive at Nabble.com.
>> 

Re: errroHandler is not redelivering

Posted by atg roxx <at...@gmail.com>.
Hi Babak,


I cant provide the logs in debug mode but assure you that
SoapFaultClientException  is getting generated.

and yes ----

<bean id="jms"
class="org.apache.activemq.camel.component.*ActiveMQComponent*">
-------------

the above is the copy paste issue;



On Mon, Jan 30, 2012 at 3:30 PM, Babak Vahdat
<ba...@swissonline.ch>wrote:

> Hi
>
> Can you turn the log level to DEBUG and send it *including* the place
> where,
> as you said, you make sure that a SoapFaultClientException is thrown?
>
> BTW I see STARS around your "ActiveMQComponent" spring bean declaration of
> yours:
>
> <bean id="jms"
> class="org.apache.activemq.camel.component.*ActiveMQComponent*">
>
> Is that just as Copy & Paste issue?
>
> Babak
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/errroHandler-is-not-redelivering-tp5438700p5441739.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>

Re: errroHandler is not redelivering

Posted by Babak Vahdat <ba...@swissonline.ch>.
Hi

Can you turn the log level to DEBUG and send it *including* the place where,
as you said, you make sure that a SoapFaultClientException is thrown?

BTW I see STARS around your "ActiveMQComponent" spring bean declaration of
yours:

<bean id="jms"
class="org.apache.activemq.camel.component.*ActiveMQComponent*">

Is that just as Copy & Paste issue?

Babak

--
View this message in context: http://camel.465427.n5.nabble.com/errroHandler-is-not-redelivering-tp5438700p5441739.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: errroHandler is not redelivering

Posted by atg roxx <at...@gmail.com>.
Any replies ???

I am stuck on this for last couple of days ... any help ??

--cheers,
atgroxx

On Sun, Jan 29, 2012 at 6:32 PM, atg roxx <at...@gmail.com> wrote:

> first thanks for replying ...
>
> Now I am using apache-camel-2.8.3 and
>
> route configuration  is
> =================
>
> @Override
> public void configure() throws Exception {
>
>
>   onException(SoapFaultClientException.class).maximumRedeliveries(2).useExponentialBackOff();
>
>
>  errorHandler(deadLetterChannel("jms:queue:dead").maximumRedeliveries(3).redeliveryDelay(5000));
>
>  from(GETLIST_JMS_URL)
>  .log("Received request for "+Constants.GETLIST)
> .to(ExchangePattern.InOut,SERVICE_URL)
>  .log("Response received from service url)
> .convertBodyTo(String.class)
>  .log("Finished processing "+Constants.GETLIS);
>  }
>
>
> I am making sure that the SERVICE_URL  route is  throwing the
> SoapFaultClientException, still the neither the  onExcetion or
> errorHandler is making the redeliveries. :(..
>
>
> *This  SERVICE_URL is a spring-ws route.*
>
> my app sequence diagram is something like  -
>
> web app post  msg to Activemq broker --> camel pick  the msg from active
> mq-> send it to third party  using (spring-ws) route. -> If camel receive
> an error or  exception it should try redelivering the msg to third party
> for N no. of times. If get a success msg then post that msg on the broker
> from where the webapp will retrive it and do the further processing.
>
> ---------------------------
>
> Also below is the setting for jms:
>
> ----------------------
>
> <bean id="jms" class="org.apache.activemq.camel.component.*
> ActiveMQComponent*">
>  <property name="configuration" ref="jmsConfig" />
> </bean>
>  <bean id="jmsConnectionFactory"
> class="org.apache.activemq.ActiveMQConnectionFactory">
> <property name="brokerURL" value="${jms.host.url}" />
>  </bean>
>
> <bean id="pooledConnectionFactory"
> class="org.apache.activemq.pool.PooledConnectionFactory">
>  <property name="maxConnections" value="20" />
> <property name="maximumActive" value="500" />
>  <property name="connectionFactory" ref="jmsConnectionFactory" />
> </bean>
>
> <bean id="jmsConfig"
> class="org.apache.camel.component.jms.JmsConfiguration">
> <property name="connectionFactory" ref="pooledConnectionFactory" />
>  </bean>
>
> ------------------------------------------------
>
>
> Is there any setting which has to be done. apart from this ??
>
>
>
>
> ---cheers,
> atgroxx
>
>
> On Sun, Jan 29, 2012 at 3:09 PM, Claus Ibsen <cl...@gmail.com>wrote:
>
>> Hi
>>
>> Can you post a few more details? Such as which Camel version you are
>> using.
>> And post your routes.
>>
>> Also notice that Camel redelivery is happening at the place of the error.
>> Where as redelivery from a JMS broker, starts all over again.
>> That is a difference.
>>
>>
>>
>> On Sat, Jan 28, 2012 at 11:32 PM, atg roxx <at...@gmail.com> wrote:
>> > Hi,
>> >
>> >
>> > I am new to camel world.
>> >
>> >
>> > I read on the camel site that we can use the below configuration to
>> > configure the route.
>> >
>> >  But the following this not taking affect. Is the some other setting
>> > which has to done somewhere ??
>> >
>> >
>> > kindly guide me .
>> >
>> > errorHandler(deadLetterChannel("jms:queue:dead")
>> >    .maximumRedeliveries(3).redeliveryDelay(5000));
>> >
>> >
>> >
>> > --cheers,
>> >
>> > atgroxx
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> FuseSource
>> Email: cibsen@fusesource.com
>> Web: http://fusesource.com
>> Twitter: davsclaus, fusenews
>> Blog: http://davsclaus.blogspot.com/
>> Author of Camel in Action: http://www.manning.com/ibsen/
>>
>
>

Re: errroHandler is not redelivering

Posted by atg roxx <at...@gmail.com>.
first thanks for replying ...

Now I am using apache-camel-2.8.3 and

route configuration  is
=================

@Override
public void configure() throws Exception {


  onException(SoapFaultClientException.class).maximumRedeliveries(2).useExponentialBackOff();


 errorHandler(deadLetterChannel("jms:queue:dead").maximumRedeliveries(3).redeliveryDelay(5000));

 from(GETLIST_JMS_URL)
 .log("Received request for "+Constants.GETLIST)
.to(ExchangePattern.InOut,SERVICE_URL)
.log("Response received from service url)
.convertBodyTo(String.class)
.log("Finished processing "+Constants.GETLIS);
 }


I am making sure that the SERVICE_URL  route is  throwing the
SoapFaultClientException, still the neither the  onExcetion or errorHandler
is making the redeliveries. :(..


*This  SERVICE_URL is a spring-ws route.*

my app sequence diagram is something like  -

web app post  msg to Activemq broker --> camel pick  the msg from active
mq-> send it to third party  using (spring-ws) route. -> If camel receive
an error or  exception it should try redelivering the msg to third party
for N no. of times. If get a success msg then post that msg on the broker
from where the webapp will retrive it and do the further processing.

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

Also below is the setting for jms:

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

<bean id="jms" class="org.apache.activemq.camel.component.*ActiveMQComponent
*">
<property name="configuration" ref="jmsConfig" />
</bean>
 <bean id="jmsConnectionFactory"
class="org.apache.activemq.ActiveMQConnectionFactory">
<property name="brokerURL" value="${jms.host.url}" />
</bean>

<bean id="pooledConnectionFactory"
class="org.apache.activemq.pool.PooledConnectionFactory">
<property name="maxConnections" value="20" />
<property name="maximumActive" value="500" />
<property name="connectionFactory" ref="jmsConnectionFactory" />
</bean>

<bean id="jmsConfig"
class="org.apache.camel.component.jms.JmsConfiguration">
<property name="connectionFactory" ref="pooledConnectionFactory" />
</bean>

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


Is there any setting which has to be done. apart from this ??




---cheers,
atgroxx

On Sun, Jan 29, 2012 at 3:09 PM, Claus Ibsen <cl...@gmail.com> wrote:

> Hi
>
> Can you post a few more details? Such as which Camel version you are using.
> And post your routes.
>
> Also notice that Camel redelivery is happening at the place of the error.
> Where as redelivery from a JMS broker, starts all over again.
> That is a difference.
>
>
>
> On Sat, Jan 28, 2012 at 11:32 PM, atg roxx <at...@gmail.com> wrote:
> > Hi,
> >
> >
> > I am new to camel world.
> >
> >
> > I read on the camel site that we can use the below configuration to
> > configure the route.
> >
> >  But the following this not taking affect. Is the some other setting
> > which has to done somewhere ??
> >
> >
> > kindly guide me .
> >
> > errorHandler(deadLetterChannel("jms:queue:dead")
> >    .maximumRedeliveries(3).redeliveryDelay(5000));
> >
> >
> >
> > --cheers,
> >
> > atgroxx
>
>
>
> --
> Claus Ibsen
> -----------------
> FuseSource
> Email: cibsen@fusesource.com
> Web: http://fusesource.com
> Twitter: davsclaus, fusenews
> Blog: http://davsclaus.blogspot.com/
> Author of Camel in Action: http://www.manning.com/ibsen/
>

Re: errroHandler is not redelivering

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Can you post a few more details? Such as which Camel version you are using.
And post your routes.

Also notice that Camel redelivery is happening at the place of the error.
Where as redelivery from a JMS broker, starts all over again.
That is a difference.



On Sat, Jan 28, 2012 at 11:32 PM, atg roxx <at...@gmail.com> wrote:
> Hi,
>
>
> I am new to camel world.
>
>
> I read on the camel site that we can use the below configuration to
> configure the route.
>
>  But the following this not taking affect. Is the some other setting
> which has to done somewhere ??
>
>
> kindly guide me .
>
> errorHandler(deadLetterChannel("jms:queue:dead")
>    .maximumRedeliveries(3).redeliveryDelay(5000));
>
>
>
> --cheers,
>
> atgroxx



-- 
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/