I am in the process of learning OSGI and I am attempting to write a simple felix shell command which tells me if a word is spelled correctly or not (using the examples as a starting point) but I'm running into problems. My manifest looks like this,

Manifest-Version: 1.0

Archiver-Version: Plexus Archiver

Created-By: Apache Maven

Built-By: jddunlap

Build-Jdk: 1.6.0_13

Bundle-Activator: tutorial.example2.Activator

Bundle-Classpath: .

Bundle-Description: A bundle that displays messages at startup and whe

 n service events occur

Bundle-Name: Service listener example

Bundle-Vendor: Apache Felix

Bundle-Version: 1.0

Import-Package: org.apache.felix.shell;version="1.4.2",org.osgi.framew

 ork



I've tried tweaking the version numbers in the manifest in every way I can think of but I continue to get the following error,

ERROR: Error starting file:/home/jddunlap/apache-felix/felix-framework-3.0.2/bundle/dictionary-service-1.0-SNAPSHOT.jar (org.osgi.framework.BundleException: Unresolved constraint in bundle [1]: Unable to resolve 1.0: missing requirement [1.0] package; (&(package=org.apache.felix.shell)(version>=1.4.2))) org.osgi.framework.BundleException: Unresolved constraint in bundle [1]: Unable to resolve 1.0: missing requirement [1.0] package; (&(package=org.apache.felix.shell)(version>=1.4.2))
        at org.apache.felix.framework.Felix.resolveBundle(Felix.java:3409)
        at org.apache.felix.framework.Felix.startBundle(Felix.java:1709)
        at org.apache.felix.framework.Felix.setActiveStartLevel(Felix.java:1143)
        at 
org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:264)
        at java.lang.Thread.run(Thread.java:619)
bundle://5.0:1/gosh_profile:15.20: ClassNotFoundException: java.lang.System
java.lang.ClassNotFoundException: java.lang.System
        at org.apache.felix.framework.Felix.loadBundleClass(Felix.java:1591)
        at org.apache.felix.framework.BundleImpl.loadClass(BundleImpl.java:887)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.felix.gogo.runtime.Reflective.method(Reflective.java:136)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:465)
        at 
org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:335)
        at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:184)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:121)
        at org.apache.felix.gogo.runtime.Closure.eval(Closure.java:265)
        at 
org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:307)
        at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:184)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:121)
at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:78)
        at org.apache.felix.gogo.shell.Shell.source(Shell.java:186)
        at org.apache.felix.gogo.shell.Shell.gosh(Shell.java:106)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.felix.gogo.runtime.Reflective.method(Reflective.java:136)
        at 
org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:82)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:421)
        at 
org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:335)
        at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:184)
        at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:121)
at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:78)
        at org.apache.felix.gogo.shell.Activator.run(Activator.java:72)
        at java.lang.Thread.run(Thread.java:619)
Caused by: org.osgi.framework.BundleException: Unresolved constraint in bundle [1]: Unable to resolve 1.0: missing requirement [1.0] package; (&(package=org.apache.felix.shell)(version>=1.4.2))
        at org.apache.felix.framework.Felix.resolveBundle(Felix.java:3409)
        at org.apache.felix.framework.Felix.loadBundleClass(Felix.java:1584)
        ... 33 more

What am I doing wrong?


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to