BTW I remember having a chat with Guillaume a while back and I don't
think the OSGi namespace in the XML is required any more; I think he
figured out how to wire in the OSGi injection without having to change
the XML namespace. Though I've not tested it to be sure though - want
to give it a try?

Then in OSGi you add camel-osgi but when not using OSGi you can omit
this dependency?

2009/3/25 Willem Jiang <willem.ji...@gmail.com>:
> Hi Aaron
>
> The CamelContextFactoryBean of OSGi version extends the
> CamelContextFactoryBean of Spring version. It only add the handle of
> bundle context injection. For non-OSGi container it will not inject the
>  bundle context into the OSGi CamelContextFactoryBean, so the OSGi
> CamelContextFactoryBean will act as Spring CamelContextFactoryBean.
>
> The only side effect is you need to add the camel-osgi dependented third
> party jars into the class path.
>
> Willem
>
> Aaron Crickenberger wrote:
>> I have the following XML I'd like to deploy both in an OSGi container, and a
>> non-OSGi container.  To deploy in the OSGi container, I have to use the
>> "osgi" schema so that the "quartz" component is resolved to the camel-quartz
>> bundle.
>>
>> To deploy in a non-OSGi container, I had to add spring-osgi-core-1.1.2.jar
>> and org.osg.core-1.2.0.jar to the classpath.  It appears to be working, but
>> I wanted to double-check with the experts.  Can you think of any
>> side-effects I might see from deploying this way vs. deploying w/ the "
>> http://activemq.apache.org/camel/schema/spring"; schema?
>>
>> <beans xmlns="http://www.springframework.org/schema/beans";
>>        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>>        xmlns:camel="http://activemq.apache.org/camel/schema/spring";
>>        xsi:schemaLocation="
>>        http://www.springframework.org/schema/beans
>> http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
>>        http://activemq.apache.org/camel/schema/spring
>> http://activemq.apache.org/camel/schema/spring/camel-spring.xsd
>>        http://activemq.apache.org/camel/schema/osgi
>> http://activemq.apache.org/camel/schema/osgi/camel-osgi.xsd";>
>>
>>   <camelContext xmlns="http://activemq.apache.org/camel/schema/osgi";>
>>     <camel:route>
>>       <camel:from uri="quartz://groupName/timerName/0,15,30,45/*/*/*/*/$" />
>>       <camel:to uri="log:ExampleRouter"/>
>>     </camel:route>
>>   </camelContext>
>>
>> </beans>
>>
>> - aaron
>>
>
>



-- 
James
-------
http://macstrac.blogspot.com/

Open Source Integration
http://fusesource.com/

Reply via email to