On Fri, Mar 1, 2013 at 1:52 PM, Smith-John <mich...@gmail.com> wrote: > In one of the plugin bundles (that implements the interface) I added in > OSGI-INF/blueprint a xml file with > > <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"> > <service id="pluginOne" ref="mockUp" > interface="pluginInterface.PluginInterface" /> > <bean id="mockUp" class="pluginMock.PluginMock" /> > </blueprint> > > and to the bundle containing camel context and the route in which I want to > call the mentioned plugin I put > > <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"> > <reference id="mockup" interface="pluginInterface.PluginInterface"/> > </blueprint> > > But .to("bean:mockup") throws > org.apache.camel.NoSuchBeanException: No bean could be found in the registry > for: mockup. > > Dont't know where the mistake is. > camel-blueprint & aries-blueprint bundles are added to run config. > > The goal is to get a plugin system, where you can start bundles during > runtime and use them. >
How do you create and start Camel in your bundle? You do not embed <camelContext> in your blueprint XML file? If not then you need to setup Camel in OSGi / blueprint. There should be a BlueprintCamelContext or something you should use then. As there is some osgi logic needed to hook into the osgi service registry when Camel does bean lookups. All that stuff is done for you when using <camelContext> > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/camel-and-several-implementations-of-an-interface-tp5728298p5728353.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: cib...@redhat.com Web: http://fusesource.com Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen