Hey, Well... I don't see your enviornment, but basically all you have to do now is to check the imports/exports of the bundles and export/import the correct classes. How exactly this works depends on your tool set. The full documentation for the maven-bundle-plugin is available here e.g. [1].
Kind regards, Andreas [1] https://felix.apache.org/site/apache-felix-maven-bundle-plugin-bnd.html On Tue, Feb 28, 2012 at 09:32, Guillaume Yziquel <[email protected]> wrote: > Le Tuesday 28 Feb 2012 à 06:15:50 (+0100), Andreas Pieber a écrit : >> Hey Guillaume, > > Hi, Andreas. > >> Can you check your logs (simply write "display" in your karaf console >> or $KARAF_HOME/data/log/karaf.log) after installing the second bundle. >> In addition can you do a "la" command showing all your installed >> bundles. If you second bundle isn't started try a start BUNDLE_ID >> which might yield a better error message on the console. >> >> Kind regards, >> Andreas > > Thanks. That really helps: > > java.lang.ClassNotFoundException: guggla.test.Sample > at > org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:506)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:422)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:410)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)[osgi-3.6.0.v20100517.jar:] > at java.lang.ClassLoader.loadClass(ClassLoader.java:248)[:1.6.0_29] > at > org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:338)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:232)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1197)[osgi-3.6.0.v20100517.jar:] > at > org.apache.felix.scr.impl.manager.ImmediateComponentManager.createImplementationObject(ImmediateComponentManager.java:178)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.manager.ImmediateComponentManager.createComponent(ImmediateComponentManager.java:118)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.manager.AbstractComponentManager$Unsatisfied.activate(AbstractComponentManager.java:997)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:333)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.manager.AbstractComponentManager.enable(AbstractComponentManager.java:157)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.config.ConfiguredComponentHolder.enableComponents(ConfiguredComponentHolder.java:256)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.BundleComponentActivator.loadDescriptor(BundleComponentActivator.java:253)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.BundleComponentActivator.initialize(BundleComponentActivator.java:147)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.BundleComponentActivator.<init>(BundleComponentActivator.java:111)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:285)[301:org.apache.felix.scr:1.6.0] > at > org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:203)[301:org.apache.felix.scr:1.6.0] > at > org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:919)[osgi-3.6.0.v20100517.jar:] > at > rg.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:227)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:149)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.Framework.publishBundleEventPrivileged(Framework.java:1349)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.Framework.publishBundleEvent(Framework.java:1300)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:380)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:284)[osgi-3.6.0.v20100517.jar:] > at > org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:276)[osgi-3.6.0.v20100517.jar:] > at > org.apache.karaf.shell.osgi.StartBundle.doExecute(StartBundle.java:29)[13:org.apache.karaf.shell.osgi:2.1.4.fuse-00-15] > at > org.apache.karaf.shell.osgi.BundlesCommand.doExecute(BundlesCommand.java:49)[13:org.apache.karaf.shell.osgi:2.1.4.fuse-00-15] > at > org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:38)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.commands.basic.AbstractCommand.execute(AbstractCommand.java:35)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.runtime.shell.CommandProxy.execute(CommandProxy.java:50)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.runtime.shell.Closure.execute(Closure.java:229)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.runtime.shell.Closure.executeStatement(Closure.java:162)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.runtime.shell.Pipe.run(Pipe.java:101)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.runtime.shell.Closure.execute(Closure.java:79)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.felix.gogo.runtime.shell.CommandSessionImpl.execute(CommandSessionImpl.java:71)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > at > org.apache.karaf.shell.console.jline.Console.run(Console.java:170)[9:org.apache.karaf.shell.console:2.1.4.fuse-00-15] > > -- > Guillaume Yziquel > Crossing-Tech > Parc Scientifique EPFL
