You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by "Richard S. Hall" <he...@ungoverned.org> on 2007/12/12 17:23:12 UTC

Re: Activator not found

First, it is probably not a good idea to have your activator in a 
package that you export, since this is unlikely to be part of your 
public API. Regarding the CNFE, I am not sure. If you look in your 
bundle, is that class actually there?

You could send me your bundle privately and I could take a look at it.

-> richard

james yong wrote:
> Hi,
>
> I encounter the following error when starting felix.
>
> ERROR: Error starting
> file:C:/workspace/ApacheWelo/bundle/com.foo.osgi.window.text_1.0.0.jar
> (org.osgi.framework.BundleException: Not found:
> com.foo.osgi.window.text.Activator)
> java.lang.ClassNotFoundException: com.foo.osgi.window.text.Activator
> 	at org.apache.felix.framework.Felix.createBundleActivator(Felix.java:3429)
> 	at org.apache.felix.framework.Felix._startBundle(Felix.java:1531)
> 	at org.apache.felix.framework.Felix.startBundle(Felix.java:1470)
> 	at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1065)
> 	at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:258)
> 	at java.lang.Thread.run(Unknown Source)
>
> Any idea?
>
> I do export the packge 
> Export-Package: com.foo.osgi.window.text
> and set
> Bundle-Activator: com.foo.osgi.window.text.Activator
>
> The bundle is created with bnd.
>
>
> Regards,
> James
>   

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Activator not found

Posted by "Richard S. Hall" <he...@ungoverned.org>.
Yes, it sounds like you are missing something...

If your bundle is self-contained and you can send it to me (off list), 
please do. I will check it out.

-> richard

james yong wrote:
> Richard S. Hall wrote:
>   
>> First, it is probably not a good idea to have your activator in a 
>> package that you export, since this is unlikely to be part of your 
>> public API. Regarding the CNFE, I am not sure. If you look in your 
>> bundle, is that class actually there?
>>
>> You could send me your bundle privately and I could take a look at it.
>>
>> -> richard
>>
>>     
>
> Hi Richard,
>
> The activator can be found now when I add its package into the private
> package definition.
> However, those classes in the com.foo.osgi.window.text.model package that
> are exported cannot be access by the activator.
>
> java.lang.NoClassDefFoundError: com/foo/osgi/window/text/model/TextWindow
> 	at com.foo.osgi.window.text.Activator.start(Activator.java:28)
> 	at
> org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:589)
> 	at org.apache.felix.framework.Felix._startBundle(Felix.java:1536)
> 	at org.apache.felix.framework.Felix.startBundle(Felix.java:1470)
> 	at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1065)
> 	at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:258)
> 	at java.lang.Thread.run(Unknown Source)
>
>
> I have checked that the classes are in the bundle.
>
> A part of the manifest file is as follow:
>
> Export-Package: com.foo.osgi.window.text.model;uses:="org.apac
>  he.wicket.velocity.markup.html,org.apache.cayenne.dba,javax.swing.tre
>  e,com.foo.cms.mgt.page,com.foo.osgi.window.text,com.foo.cms.dao,org.
>  apache.cayenne.map,org.apache.wicket.util.reso
>  urce,com.foo.osgi.service,org.apache.wicket.markup.html.panel
>  ,com.foo.model,javax.sql,org.apache.cayenne,org.apache.wicket
>  .model,org.apache.cayenne.access,org.apache.cayenne.conf,org.apache.c
>  ayenne.query"
> Private-Package: com.foo.osgi.window.text
>
> Am I missing something? Let me know if you requires the bundle. Thanks.
>
> Regards,
> James
>   

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Activator not found

Posted by james yong <i_...@yahoo.com.sg>.

Richard S. Hall wrote:
> 
> First, it is probably not a good idea to have your activator in a 
> package that you export, since this is unlikely to be part of your 
> public API. Regarding the CNFE, I am not sure. If you look in your 
> bundle, is that class actually there?
> 
> You could send me your bundle privately and I could take a look at it.
> 
> -> richard
> 

Hi Richard,

The activator can be found now when I add its package into the private
package definition.
However, those classes in the com.foo.osgi.window.text.model package that
are exported cannot be access by the activator.

java.lang.NoClassDefFoundError: com/foo/osgi/window/text/model/TextWindow
	at com.foo.osgi.window.text.Activator.start(Activator.java:28)
	at
org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:589)
	at org.apache.felix.framework.Felix._startBundle(Felix.java:1536)
	at org.apache.felix.framework.Felix.startBundle(Felix.java:1470)
	at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1065)
	at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:258)
	at java.lang.Thread.run(Unknown Source)


I have checked that the classes are in the bundle.

A part of the manifest file is as follow:

Export-Package: com.foo.osgi.window.text.model;uses:="org.apac
 he.wicket.velocity.markup.html,org.apache.cayenne.dba,javax.swing.tre
 e,com.foo.cms.mgt.page,com.foo.osgi.window.text,com.foo.cms.dao,org.
 apache.cayenne.map,org.apache.wicket.util.reso
 urce,com.foo.osgi.service,org.apache.wicket.markup.html.panel
 ,com.foo.model,javax.sql,org.apache.cayenne,org.apache.wicket
 .model,org.apache.cayenne.access,org.apache.cayenne.conf,org.apache.c
 ayenne.query"
Private-Package: com.foo.osgi.window.text

Am I missing something? Let me know if you requires the bundle. Thanks.

Regards,
James
-- 
View this message in context: http://www.nabble.com/Activator-not-found-tp14298496p14352620.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org