You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Vishal Changrani <vi...@ericsson.com> on 2013/01/25 16:56:27 UTC

Persisting route details..

Hi,

There are a couple of use-cases that I want to address -
1. Persisting all routes last start-time and end-time somehow so that on the application server startup routes do not start if they have just recently ran and also to report route statistics.
2.Modifying the routes such that the changes don't take effect untill the current exchange finishes.

Can anyone share their insights if they have done something similar?
I have Camel running in Jboss with Oracle at the backend. I was thinking of creating a table - route_status to persist all this information but was wondering if there is a better approach.

Thanks,
V


Re: Persisting route details..

Posted by vishal1981 <vi...@ericsson.com>.
thanks for the replies.



--
View this message in context: http://camel.465427.n5.nabble.com/Persisting-route-details-tp5726275p5727048.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Persisting route details..

Posted by Hadrian Zbarcea <hz...@gmail.com>.
Camel currently is essentially stateless. You can achieve what you want, 
but you'd have to implement it yourself. Something along the lines you 
mentioned.

We are however planning to have support for persistence at a core level 
in 3.0. Christian Ohr added some details about that on the 3.0 ideas 
page [1] (near the bottom of the page).

[1] http://cwiki.apache.org/confluence/display/CAMEL/Camel+3.0+-+Ideas

Cheers
Hadrian

On 01/25/2013 10:56 AM, Vishal Changrani wrote:
> Hi,
>
> There are a couple of use-cases that I want to address -
> 1. Persisting all routes last start-time and end-time somehow so that on the application server startup routes do not start if they have just recently ran and also to report route statistics.
> 2.Modifying the routes such that the changes don't take effect untill the current exchange finishes.
>
> Can anyone share their insights if they have done something similar?
> I have Camel running in Jboss with Oracle at the backend. I was thinking of creating a table - route_status to persist all this information but was wondering if there is a better approach.
>
> Thanks,
> V
>
>

Re: Persisting route details..

Posted by Claus Ibsen <cl...@gmail.com>.
On Fri, Jan 25, 2013 at 4:56 PM, Vishal Changrani
<vi...@ericsson.com> wrote:
> Hi,
>
> There are a couple of use-cases that I want to address -
> 1. Persisting all routes last start-time and end-time somehow so that on the application server startup routes do not start if they have just recently ran and also to report route statistics.

You can look at the event notifier API it has events for routes
starting | stopping. etc
Or the JMX management API etc.



> 2.Modifying the routes such that the changes don't take effect untill the current exchange finishes.
>

There is JMX API for knowing the number of in-flight exchanges.
Or the API from
http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/InflightRepository.html

The in-flight registry is used by Camel itself when it graceful shutdown etc
http://camel.apache.org/graceful-shutdown.html


> Can anyone share their insights if they have done something similar?
> I have Camel running in Jboss with Oracle at the backend. I was thinking of creating a table - route_status to persist all this information but was wondering if there is a better approach.
>
> Thanks,
> V
>



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Re: Persisting route details..

Posted by vishal1981 <vi...@ericsson.com>.
Alright thanks a lot guys



--
View this message in context: http://camel.465427.n5.nabble.com/Persisting-route-details-tp5726275p5726525.html
Sent from the Camel - Users mailing list archive at Nabble.com.