That sounds more like you have the wrong dependencies loading or an ordering issue. Lines 4 & 5 and 8 & 9. Are those different versions of the OSGi interfaces?
On Mon, Oct 29, 2012 at 4:14 PM, Kjell Otto <[email protected]> wrote: > Hi Scott, > > thanks for your answer but it seems that this is not helping. > Even worse, if I include the dependency: > > <dependency> > <groupId>org.apache.felix</groupId> > <artifactId>org.apache.felix.metatype</artifactId> > <version>1.0.4</version> > </dependency> > > START LEVEL 6 > ID|State |Level|Name > 0|Active | 0|System Bundle (4.0.2) > 1|Active | 1|Apache Felix Gogo Shell (0.10.0) > 2|Active | 1|Apache Felix Gogo Runtime (0.10.0) > 3|Active | 5|Apache Felix Metatype Service (1.0.4) > 4|Active | 5|OSGi R4 Core Bundle (4.0.0) > 5|Active | 5|OSGi R4 Compendium Bundle (4.0.0) > 6|Active | 5|Servlet 2.1 API (1.0.0) > 7|Active | 5|Apache Felix Log Service (1.0.1) > 8|Active | 5|osgi.core (4.1.0.build-200702212030) > 9|Active | 5|osgi.compendium (4.1.0.build-200702212030) > 10|Active | 5|Apache Felix Declarative Services (1.6.0) > 11|Active | 5|Apache Felix Configuration Admin Service (1.4.0) > 12|Active | 5|Apache Felix Bundle Repository (1.6.6) > 13|Active | 5|Apache ServiceMix :: Bundles :: jaxb-xjc (2.2.4.2) > 14|Active | 5|Apache ServiceMix :: Bundles :: jaxb-impl (2.2.4.2) > 15|Active | 5|geronimo-activation_1.1_spec (1.0.2) > 16|Active | 5|Apache ServiceMix Specs :: STAX API 1.0 (1.0.0) > 17|Active | 5|Apache ServiceMix :: Specs :: JAXB API 2.2 (1.6.0) > 18|Active | 5|Apache ServiceMix :: Bundles :: xstream (1.4.3.1) > 19|Active | 5|Apache ServiceMix :: Bundles :: protobuf-java > (2.4.1.1) > 20|Active | 5|Apache ServiceMix :: Bundles :: stax-utils > (20070216.0.0.1) > 21|Active | 5|Apache ServiceMix :: Bundles :: woodstox (3.2.9.3) > 22|Active | 5|Apache ServiceMix :: Bundles :: antlr-runtime > (3.4.0.2) > 23|Active | 5|Apache ServiceMix :: Bundles :: antlr (3.4.0.1) > 24|Active | 5|Apache ServiceMix :: Bundles :: ant (1.8.4.1) > ... > 44|Active | 1|Apache Felix Gogo Command (0.12.0) > > > It shows up as Active, but for all my self defined Service Components > through the scr plugin, I get these exceptions: > > Cannot register Component - java.lang.ClassCastException: > org.apache.felix.cm.impl.ConfigurationAdminImpl cannot be cast to > org.osgi.service.cm.ConfigurationAdmin > at > org.apache.felix.scr.impl.config.ConfigurationComponentRegistry.createComponentHolder(ConfigurationComponentRegistry.java:125) > at > org.apache.felix.scr.impl.BundleComponentActivator.loadDescriptor(BundleComponentActivator.java:244) > at > org.apache.felix.scr.impl.BundleComponentActivator.initialize(BundleComponentActivator.java:147) > at > org.apache.felix.scr.impl.BundleComponentActivator.<init>(BundleComponentActivator.java:111) > at > org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:285) > at > org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:203) > at > org.apache.felix.framework.util.EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:868) > at > org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:789) > at > org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:514) > at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:4244) > at org.apache.felix.framework.Felix.startBundle(Felix.java:1923) > at > org.apache.felix.framework.Felix.setActiveStartLevel(Felix.java:1191) > at > org.apache.felix.framework.FrameworkStartLevelImpl.run(FrameworkStartLevelImpl.java:295) > at java.lang.Thread.run(Thread.java:680) > > Am I doing something wrong in the other bundles? Or what is my problem here? > Any further hints would be great! > > Greetings, > Kjellski > > > 2012/10/29 Scott England-Sullivan <[email protected]>: >> Hi Kjellksi, >> >> Try deploying MetaType. I believe that should allow it to activate. >> >> Best Regards, >> Scott ES >> >> On Mon, Oct 29, 2012 at 8:56 AM, Kjell Otto <[email protected]> wrote: >>> Hi there, >>> >>> I can't see any of the scr commands in the shell. >>> >>> Issueing the help command shows this: >>> >>> felix:bundlelevel >>> felix:cd >>> felix:frameworklevel >>> felix:headers >>> felix:help >>> felix:inspect >>> felix:install >>> felix:lb >>> felix:log >>> felix:ls >>> felix:refresh >>> felix:resolve >>> felix:start >>> felix:stop >>> felix:uninstall >>> felix:update >>> felix:which >>> gogo:cat >>> gogo:each >>> gogo:echo >>> gogo:format >>> gogo:getopt >>> gogo:gosh >>> gogo:grep >>> gogo:not >>> gogo:set >>> gogo:sh >>> gogo:source >>> gogo:tac >>> gogo:telnetd >>> gogo:type >>> gogo:until >>> obr:deploy >>> obr:info >>> obr:javadoc >>> obr:list >>> obr:repos >>> obr:source >>> >>> And the service is running properly: >>> >>> g! lb >>> START LEVEL 6 >>> ID|State |Level|Name >>> 0|Active | 0|System Bundle (4.0.2) >>> 1|Active | 1|Apache Felix Gogo Shell (0.10.0) >>> 2|Active | 1|Apache Felix Gogo Runtime (0.10.0) >>> 3|Active | 5|Apache Felix Log Service (1.0.1) >>> 4|Active | 5|osgi.core (4.1.0.build-200702212030) >>> 5|Active | 5|osgi.compendium (4.1.0.build-200702212030) >>> 6|Active | 5|Apache Felix Declarative Services (1.6.0) >>> 7|Active | 5|Apache Felix Configuration Admin Service (1.4.0) >>> 8|Active | 5|Apache Felix Bundle Repository (1.6.6) >>> 40|Active | 1|Apache Felix Gogo Command (0.12.0) >>> >>> Any ideas? Do I need to explicitly provision a bundle for the commands >>> in addition? >>> >>> Greetings, >>> Kjellksi >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: [email protected] >>> For additional commands, e-mail: [email protected] >>> >> >> >> >> -- >> -- >> Scott England-Sullivan >> Apache Camel Committer >> Principal Consultant / Sr. Architect | Red Hat, Inc. >> FuseSource is now part of Red Hat >> Web: fusesource.com | redhat.com >> Blog: sully6768.blogspot.com >> Twitter: sully6768 >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > -- -- Scott England-Sullivan Apache Camel Committer Principal Consultant / Sr. Architect | Red Hat, Inc. FuseSource is now part of Red Hat Web: fusesource.com | redhat.com Blog: sully6768.blogspot.com Twitter: sully6768 --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]

