FAQ
Hello:
I have been able to successfully suspend and resume routes using the
relevant JMX operations. However, when the container [app server] is
restarted, the routes again start up which I do not want. I want that
whatever routes have been suspended should remain so even after server
restarts till the time I explicitly resume them again. Is it possible to
implement this somehow?
Regards,
Sushil



--
View this message in context: http://camel.465427.n5.nabble.com/Permanent-Suspension-of-Routes-tp5729614.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Search Discussions

  • Christian Müller at Mar 21, 2013 at 10:40 pm
    Camel doesn't persist the state of a route right now. You can only
    configure whether a route should be start if the context is started or not.

    Best,
    Christian
    On Thu, Mar 21, 2013 at 2:20 PM, sushil_vsk5 wrote:

    Hello:
    I have been able to successfully suspend and resume routes using the
    relevant JMX operations. However, when the container [app server] is
    restarted, the routes again start up which I do not want. I want that
    whatever routes have been suspended should remain so even after server
    restarts till the time I explicitly resume them again. Is it possible to
    implement this somehow?
    Regards,
    Sushil



    --
    View this message in context:
    http://camel.465427.n5.nabble.com/Permanent-Suspension-of-Routes-tp5729614.html
    Sent from the Camel - Users mailing list archive at Nabble.com.


    --
  • Claus Ibsen at Mar 22, 2013 at 6:56 am

    On Thu, Mar 21, 2013 at 2:20 PM, sushil_vsk5 wrote:
    Hello:
    I have been able to successfully suspend and resume routes using the
    relevant JMX operations. However, when the container [app server] is
    restarted, the routes again start up which I do not want. I want that
    whatever routes have been suspended should remain so even after server
    restarts till the time I explicitly resume them again. Is it possible to
    implement this somehow?
    Regards,
    Sushil
    I guess setting autoStartup false on camel context.
    And use an event listener, and listen when camel has been started.

    And then load from a persisten store the data that tells you which
    routes to start.
    Then start them using the api on CamelContext.

    And the even listener allows you to keep track when a route is stopped
    also. Then you can update
    your persisten store to reflect that change.

    A little example about the event notifier is here
    http://camel.apache.org/eventnotifier-to-log-details-about-all-sent-exchanges.html

    And the even objects we have is in this package
    http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/management/event/package-summary.html


    --
    View this message in context: http://camel.465427.n5.nabble.com/Permanent-Suspension-of-Routes-tp5729614.html
    Sent from the Camel - Users mailing list archive at Nabble.com.


    --
    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
  • Christian Müller at Mar 22, 2013 at 8:04 am
    Yeah, that sounds good...

    Best,
    Christian
    On Fri, Mar 22, 2013 at 7:55 AM, Claus Ibsen wrote:
    On Thu, Mar 21, 2013 at 2:20 PM, sushil_vsk5 wrote:
    Hello:
    I have been able to successfully suspend and resume routes using the
    relevant JMX operations. However, when the container [app server] is
    restarted, the routes again start up which I do not want. I want that
    whatever routes have been suspended should remain so even after server
    restarts till the time I explicitly resume them again. Is it possible to
    implement this somehow?
    Regards,
    Sushil
    I guess setting autoStartup false on camel context.
    And use an event listener, and listen when camel has been started.

    And then load from a persisten store the data that tells you which
    routes to start.
    Then start them using the api on CamelContext.

    And the even listener allows you to keep track when a route is stopped
    also. Then you can update
    your persisten store to reflect that change.

    A little example about the event notifier is here

    http://camel.apache.org/eventnotifier-to-log-details-about-all-sent-exchanges.html

    And the even objects we have is in this package

    http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/management/event/package-summary.html


    --
    View this message in context:
    http://camel.465427.n5.nabble.com/Permanent-Suspension-of-Routes-tp5729614.html
    Sent from the Camel - Users mailing list archive at Nabble.com.


    --
    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


    --

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupusers @
categoriescamel
postedMar 21, '13 at 1:23p
activeMar 22, '13 at 8:04a
posts4
users3
websitecamel.apache.org

People

Translate

site design / logo © 2022 Grokbase