Hello Han,

You should make sure there is a line break after the last line of the manifest, otherwise it will not be processed (and, indeed, the NCDFE you get is caused by a class coming from org.osgi.framework).

Angelo

On 22 Jan 2008, at 10:05, Han Liu wrote:

The NoClassDefFoundError: org/osgi/framework/BundleActivator

I got the exception below

org.osgi.framework.BundleException: Activator start error.
        at org.apache.felix.framework.Felix._startBundle(Felix.java:1580)
        at org.apache.felix.framework.Felix.startBundle(Felix.java:1470)
        at org.apache.felix.framework.BundleImpl.start(BundleImpl.java:354)
at org .apache .felix.shell.impl.StartCommandImpl.execute(StartCommandImpl.java:82) at org.apache.felix.shell.impl.Activator $ShellServiceImpl.executeCommand(Activator.java:265) at org.apache.felix.shell.tui.Activator $ShellTuiRunnable.run(Activator.java:167)
        at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.NoClassDefFoundError: org/osgi/framework/ BundleActivator
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
at org .apache .felix .framework .searchpolicy.ContentClassLoader.findClass(ContentClassLoader.java: 162) at org .apache .felix .framework .searchpolicy .ContentClassLoader.loadClassFromModule(ContentClassLoader.java:51) at org .apache .felix .framework .searchpolicy.ContentLoaderImpl.getClass(ContentLoaderImpl.java:121) at org .apache .felix .framework .searchpolicy .R4SearchPolicyCore.findClassOrResource(R4SearchPolicyCore.java:397) at org .apache .felix .framework .searchpolicy.R4SearchPolicyCore.findClass(R4SearchPolicyCore.java: 175) at org .apache .felix .framework.searchpolicy.R4SearchPolicy.findClass(R4SearchPolicy.java: 45) at org.apache.felix.moduleloader.ModuleImpl.getClass(ModuleImpl.java:152) at org.apache.felix.framework.Felix.createBundleActivator(Felix.java: 3426)
        at org.apache.felix.framework.Felix._startBundle(Felix.java:1531)
        ... 6 more
java.lang.NoClassDefFoundError: org/osgi/framework/BundleActivator



the manifest file is

Bundle-Name: English dictionary
Bundle-Description: A bundle that registers an English dictionary service
Bundle-Vendor: Apache Felix
Bundle-Version: 1.0.0
Bundle-Activator: example.dictionary.Activator
Import-Package: org.osgi.framework

and there is nothing special  in example.dictionary.Activator (It is a
copy of the example)


I'm a starter,  and I'm so upset to meet the problem. I am using JDK6



2 Is that the contexts in each bundle activator's start method are different?

3 How to install a bundle in program without typing command in the shell.

---------------------------------------------------------------------
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]

Reply via email to