Re: Activemq dynamic endpoint configuration

2011-10-03 Thread Claus Ibsen
On Tue, Oct 4, 2011 at 1:29 AM, kal2420 wrote: > Claus, > >    What is the proper way to shutdown the route? I am doing the following > from RouteBuilder: > >     getContext().stopRoute(routeID); > >  But when I do that, I all the routes being shutdown. is this correct ?  I > see it invoking  "o

Re: Activemq dynamic endpoint configuration

2011-10-03 Thread kal2420
Claus, What is the proper way to shutdown the route? I am doing the following from RouteBuilder: getContext().stopRoute(routeID); But when I do that, I all the routes being shutdown. is this correct ? I see it invoking "org.apache.camel.impl.DefaultShutdownStrategy$ShutdownTasK "

Re: Activemq dynamic endpoint configuration

2011-09-30 Thread Claus Ibsen
On Fri, Sep 30, 2011 at 1:42 AM, kal2420 wrote: > Thanks Clause,  I will give it a try this week end and see how it goes. > Starting and stoping the route seems a bit expensive, can I use suspend and > resume? > You can try. But you may have to stop for the selector to be updated. But give it a

Re: Activemq dynamic endpoint configuration

2011-09-29 Thread kal2420
Thanks Clause, I will give it a try this week end and see how it goes. Starting and stoping the route seems a bit expensive, can I use suspend and resume? Thanks Kal On Sep 28, 2011, at 2:01 AM, Claus Ibsen-2 [via Camel] wrote: > Hi > > Yes you would need to stop the route. Adjust the endp

Re: Activemq dynamic endpoint configuration

2011-09-27 Thread Claus Ibsen
Hi Yes you would need to stop the route. Adjust the endpoint. And start the route again to have the JMS selector dynamic updated. CamelContext has API to start/stop rotues by the route id. On Wed, Sep 28, 2011 at 5:10 AM, kal2420 wrote: > Thanks Claus, > >    This example is very helpful, I am

Re: Activemq dynamic endpoint configuration

2011-09-27 Thread kal2420
Thanks Claus, This example is very helpful, I am still running into a bit of an issues. Here is my createRouteBuilder() method ( combined JmsSelectorTest and JmsSelectorInTest ) : @Override protected RouteBuilder createRouteBuilder() throws Exception { return new RouteBuild

Re: Activemq dynamic endpoint configuration

2011-09-27 Thread Claus Ibsen
Hi I created an unit test which you can take a look at. It uses the IN selector http://svn.apache.org/viewvc?rev=1176348&view=rev On Tue, Sep 27, 2011 at 1:58 PM, Claus Ibsen wrote: > On Mon, Sep 26, 2011 at 6:05 PM, kal2420 wrote: >> Thanks Claus, >> >>     I got busy with work, and I am just

Re: Activemq dynamic endpoint configuration

2011-09-27 Thread Claus Ibsen
On Mon, Sep 26, 2011 at 6:05 PM, kal2420 wrote: > Thanks Claus, > >     I got busy with work, and I am just getting back to camel. I did try > looking into event-driven-consusmer, What i really want is to configure > dynamic selector on activemq queue. Here is how I am trying to configure > dynami

Re: Activemq dynamic endpoint configuration

2011-09-26 Thread kal2420
Thanks Claus, I got busy with work, and I am just getting back to camel. I did try looking into event-driven-consusmer, What i really want is to configure dynamic selector on activemq queue. Here is how I am trying to configure dynamic selector, please tell me if this is correct: // once al

RE: Activemq dynamic endpoint configuration

2011-09-06 Thread kal2420
mrlalonde wrote: > > > I think you are on the right track with thoughts on polled endpoints. > I you are looking to consume messages when a state changes, you could > generate application events when that happens and use a pollEnrich(...) > eip. > > Something like: > > from("spring-event://def

Re: Activemq dynamic endpoint configuration

2011-09-02 Thread Mick Knutson
I looked at that link and did not see an example of how to use the event driven consumer. Are there any code examples? --- Thank You… Mick Knutson, President BASE Logic, Inc. Enterprise Architecture, Design, Mentoring & Agile Consulting p. (855) BASE-LOGIC: (227-3564-42) p. (478) BASE-LOGIC (227

Re: Activemq dynamic endpoint configuration

2011-09-01 Thread Claus Ibsen
The configure method is called *once* when Camel bootup and create the runtime routes from the model (eg RouteBuilder's). The JMS consumer is an event driven consumer http://camel.apache.org/event-driven-consumer.html On Fri, Sep 2, 2011 at 1:57 AM, kal2420 wrote: > Ashwin, > >   Thanks, I ag

RE: Activemq dynamic endpoint configuration

2011-09-01 Thread Mathieu Lalonde
t; Date: Thu, 1 Sep 2011 16:57:08 -0700 > From: kalpi...@cisco.com > To: users@camel.apache.org > Subject: Re: Activemq dynamic endpoint configuration > > Ashwin, > > Thanks, I agree this is a bad approach. I am a bit confused about how > often configure() method is invoked

Re: Activemq dynamic endpoint configuration

2011-09-01 Thread kal2420
Ashwin, Thanks, I agree this is a bad approach. I am a bit confused about how often configure() method is invoked and when the message would be read from the queue. For Example: public class TestRouteBuilder extends RouteBuilder { public String current_State = "process"; @Overrid

Re: Activemq dynamic endpoint configuration

2011-09-01 Thread Ashwin Karpe
Hi, I believe you are going about this completely wrong. What you need is to set up an EventManager object/entity that can keep an eye on ActiveMQ using Advisory queues/topics or JMX to figure out the queues and whether there are messages on these queues/topics. The this EventManager needs to b