Re: Headers set from custom component are lost on exception

2014-01-28 Thread Lorenzo Bolzani
2014-01-21 Claus Ibsen > Hi > > Yeah that is intended as when an exception occurs the exchange does > not include any partial changes/updates that may have happened. > Camel does a defensive copy of the information from the message in its > error handler. > Hi Claus, thanks for your reply. I f

Headers set from custom component are lost on exception

2014-01-20 Thread Lorenzo Bolzani
Hi, I have a custom camel component (a producer) that works like this try { doSomething(); exchange.getIn().setHeader("result", "123"); } catch(...) { exchange.getIn().setHeader("problem", "this"); throw new SomeException(...); } Now in my route I never see the "problem" header when

Re: When - an Apache Camel Component for time slots management

2013-11-11 Thread Lorenzo Bolzani
2013/11/11 Jan Matèrne (jhm) : >> I was able to get this working >> >> from("direct:start").filter("when", "MON-FRI 9:30-18:30").to(...) > > Does that matches the current system time? Yes. You can also define an header called "when.date" to do the matching on this one instead. I do not like this

Re: When - an Apache Camel Component for time slots management

2013-11-11 Thread Lorenzo Bolzani
2013/11/11 Claus Ibsen : > Hi > > Nice work keep it going. > > A cron like predicate would be nice. Hi Claus, thanks, I'll consider this. I was able to get this working from("direct:start").filter("when", "MON-FRI 9:30-18:30").to(...) but I'm struggling with the matches method. This works:

Re: When - an Apache Camel Component for time slots management

2013-11-10 Thread Lorenzo Bolzani
org/simple.html) > > Kind regards, > > Christoph > > > On 10 Nov 2013, at 15:14, Lorenzo Bolzani wrote: > > Hi, > I just created this very simple component to allow/suspend a service at > certain times. > > > https://bitbucket.org/nottrz/when > > > Any feedback is welcome. > > > > Bye > > Lorenzo > >

When - an Apache Camel Component for time slots management

2013-11-10 Thread Lorenzo Bolzani
Hi, I just created this very simple component to allow/suspend a service at certain times. https://bitbucket.org/nottrz/when Any feedback is welcome. Bye Lorenzo