On Mon, Oct 29, 2012 at 1:09 PM, Benjamin Graf <benjamin.g...@gmx.net> wrote:
> The "poor" OSGi runtime is JBoss OSGi which is still a technology preview but 
> is a feature of JBoss AS7.
>
> I know Karaf but it is no alternative for me. Might change sometime if karaf 
> has been integrated into JBoss.
>
> May be the Fuse (RedHat) guys out there can tell something about that! ;-)

I could tell you, but then I would have to kill you :) Okay just
kidding of course.

I know the autoStartup name is a poor name on the <camelContext> but
it was as said inheirted from the routes.
Are you using spring-dm or OSGi Blueprint? I think in the latter we
have a sort of a "hack" to disable starting CamelContext, which is
used for some special tests. There is a static method on
SpringCamelContext which can be set to true to not start.

As we need to preserve backwards compatibility I wonder if we should
introduce a new option on CamelContext to instruct it to skip
starting. But if so, what should it do?

How would you start it? As it would possible need some logic to at
least bootstrap a piece so it can either
- enlist a CamelContextMBean in JMX so you can start it from JMX.
- register a CamelContext in OSGi service registry so you can start it from OSGi
- or as now, but just have its state listed as started=false,
stopped=true. But do all its boostrap logic to enlist routes im JMX,
osgi stuff and whatnot.




>
> -------- Original-Nachricht --------
>> Datum: Mon, 29 Oct 2012 12:21:24 +0100
>> Von: Claus Ibsen <claus.ib...@gmail.com>
>> An: users@camel.apache.org
>> Betreff: Re: Camel context autostartup
>
>> On Mon, Oct 29, 2012 at 11:36 AM, Benjamin Graf <benjamin.g...@gmx.net>
>> wrote:
>> >
>> > -------- Original-Nachricht --------
>> >> Datum: Mon, 29 Oct 2012 10:30:36 +0100
>> >> Von: Claus Ibsen <claus.ib...@gmail.com>
>> >> An: users@camel.apache.org
>> >> Betreff: Re: Camel context autostartup
>> >
>> >> On Mon, Oct 29, 2012 at 10:25 AM, Benjamin Graf <benjamin.g...@gmx.net>
>> >> wrote:
>> >> > Hi Claus,
>> >> >
>> >> > thanks so far. But does any method exists to avoid auto starting
>> context
>> >> using Spring OSGi with bundles activated?
>> >> >
>> >>
>> >> No, but you can if possible just dont start the bundle itself. And
>> >> then start the bundle to start Camel.
>> >
>> > Well, that's a problem. My OSGi runtime does not support this feature
>> yet. :-( I was hoping camel autostartup is a good workaround.
>> >
>>
>> This must be a poor OSGi runtime, which can't manage lifecycle of the
>> bundles.
>> What do you use?
>>
>> And I am sure you are aware of Apache Karaf which is a great OSGi runtime.
>> http://karaf.apache.org/
>>
>>
>> >>
>> >> The problem is that there is a chicken-egg situation. CamelContext
>> >> need to be started so people can start it, using eg JMX etc.
>> >> And for that the context needs to be started to enlist in JMX etc.
>> >
>> > That's why I actually have written my own JMX Service for
>> starting/stopping context via JMX which is not dependant if context has been 
>> started yet.
>> >
>> > Maybe worth changing that behaviour at all?
>> >
>> >>
>> >>
>> >>
>> >> > Benjamin
>> >> >
>> >> > -------- Original-Nachricht --------
>> >> >> Datum: Mon, 29 Oct 2012 09:33:49 +0100
>> >> >> Von: Claus Ibsen <claus.ib...@gmail.com>
>> >> >> An: users@camel.apache.org
>> >> >> Betreff: Re: Camel context autostartup
>> >> >
>> >> >> The autostartup options is for controlling if *routes* should be
>> auto
>> >> >> started or not.
>> >> >> Not the actual CamelContext itself.
>> >> >>
>> >> >> The naming could have been better, but the option was first on
>> <route>
>> >> >> and then later inherited on <camelContext> to make a single switch.
>> >> >>
>> >> >>
>> >> >> On Sat, Oct 27, 2012 at 4:57 PM, Benjamin Graf
>> <benjamin.g...@gmx.net>
>> >> >> wrote:
>> >> >> > Hi,
>> >> >> >
>> >> >> > can anybody explain me why camel context state is set to started
>> if
>> >> >> autostartup
>> >> >> > is set to false? This sound a bit odd to me.
>> >> >> >
>> >> >> > Best,
>> >> >> > Benjamin
>> >> >> >
>> >> >>
>> >> >>
>> >> >>
>> >> >> --
>> >> >> Claus Ibsen
>> >> >> -----------------
>> >> >> Red Hat, Inc.
>> >> >> FuseSource is now part of Red Hat
>> >> >> Email: cib...@redhat.com
>> >> >> Web: http://fusesource.com
>> >> >> Twitter: davsclaus
>> >> >> Blog: http://davsclaus.com
>> >> >> Author of Camel in Action: http://www.manning.com/ibsen
>> >>
>> >>
>> >>
>> >> --
>> >> Claus Ibsen
>> >> -----------------
>> >> Red Hat, Inc.
>> >> FuseSource is now part of Red Hat
>> >> Email: cib...@redhat.com
>> >> Web: http://fusesource.com
>> >> Twitter: davsclaus
>> >> Blog: http://davsclaus.com
>> >> Author of Camel in Action: http://www.manning.com/ibsen
>>
>>
>>
>> --
>> Claus Ibsen
>> -----------------
>> Red Hat, Inc.
>> FuseSource is now part of Red Hat
>> Email: cib...@redhat.com
>> Web: http://fusesource.com
>> Twitter: davsclaus
>> Blog: http://davsclaus.com
>> Author of Camel in Action: http://www.manning.com/ibsen



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

Reply via email to