camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anto Paul <antopaul.l...@gmail.com>
Subject Re: How to change Camel endpoint at run time?
Date Fri, 20 Nov 2009 04:18:56 GMT
Hi,
    As an example take an FTP poller that has to connect to a server when a
particular event is triggered. We have to provide a UI to the end user who
can change the FTP server address at anytime. He can add more servers or
remove server or change an existing server. AFAIK Camel 2.0 cannot delete a
route once it is defined. What I learned from mail archives is that Camel
context has to be stopped to destroy a route. I also read in the 2.1 release
notes that the ability to add/stop route feature is added.

    BTW with 2.0, I tried to remove an endpoint like this and it is still
sending messages to that endpoint.

          context.removeEndpoints("vm://a")

Anto


On Thu, Nov 19, 2009 at 7:05 PM, Claus Ibsen <claus.ibsen@gmail.com> wrote:

> On Thu, Nov 19, 2009 at 6:27 AM, Anto Paul <antopaul.list@gmail.com>
> wrote:
> > Hi,
> >   I need to add/remove endpoint URI at runtime when user
> > adds/removes/updates the URI using a web application. I need to expose
> > HTTP,FTP,web service and JMS endpoints as consumers and producers. On
> > searching mail archive the solution I found is to stop camel context to
> stop
> > a route.
> >
>
> Hi
>
> Can you tell a bit more what you mean by add/remove endpoint at runtime?
> Can you give a little example?
>
> You can use the Camel API to create routes at runtime.
> And the same API to stop/start routes etc.
>
>
>
>
> --
> Claus Ibsen
> Apache Camel Committer
>
> Author of Camel in Action: http://www.manning.com/ibsen/
> Open Source Integration: http://fusesource.com
> Blog: http://davsclaus.blogspot.com/
> Twitter: http://twitter.com/davsclaus
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message