You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by lo...@bull.net on 2012/12/06 17:23:30 UTC

[iPOJO] class loading issue with iPOJO Event Admin Handler 1.8.0 and iPOJO core 1.8.4

Hi Felix users/devs,

I'm facing an issue when upgrading my iPOJO artifacts to the latest versions.
I'm using the iPOJO Event Admin Handler 1.8.0 and iPOJO Core 1.8.4.
When using the Event Admin Handler I get a java.lang.ClassNotFoundException on org.apache.felix.ipojo.handlers.event.EventUtil

2012-12-06 16:30:17,709 : LoggerService.log : [ERROR] IPOJO-Extender : An error occurs when analyzing the content or starting the management of 103
java.lang.NoClassDefFoundError: org/apache/felix/ipojo/handlers/event/EventUtil
        at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberMetadata.setTopics(EventAdminSubscriberMetadata.java:217)
        at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberMetadata.<init>(EventAdminSubscriberMetadata.java:148)
        at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberHandler.__initializeComponentFactory(EventAdminSubscriberHandler.java:143)
        at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberHandler.initializeComponentFactory(EventAdminSubscriberHandler.java)
        at org.apache.felix.ipojo.IPojoFactory.computeDescription(IPojoFactory.java:724)
        at org.apache.felix.ipojo.IPojoFactory.computeFactoryState(IPojoFactory.java:757)
        at org.apache.felix.ipojo.ComponentFactory.addedService(ComponentFactory.java:414)
        at org.apache.felix.ipojo.util.Tracker$Tracked.trackAdding(Tracker.java:725)
        at org.apache.felix.ipojo.util.Tracker$Tracked.trackInitialServices(Tracker.java:610)
        at org.apache.felix.ipojo.util.Tracker.open(Tracker.java:210)
        at org.apache.felix.ipojo.ComponentFactory.starting(ComponentFactory.java:262)
        at org.apache.felix.ipojo.IPojoFactory.start(IPojoFactory.java:605)
        at org.apache.felix.ipojo.Extender.createAbstractFactory(Extender.java:520)
        at org.apache.felix.ipojo.Extender.parse(Extender.java:301)
        at org.apache.felix.ipojo.Extender.startManagementFor(Extender.java:237)
        at org.apache.felix.ipojo.Extender.access$600(Extender.java:52)
        at org.apache.felix.ipojo.Extender$CreatorThread.run(Extender.java:769)
        at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.ClassNotFoundException: org.apache.felix.ipojo.handlers.event.EventUtil not found by org.apache.felix.ipojo [8]
        at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1460)
        at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:72)
        at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1843)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
        at org.apache.felix.framework.BundleWiringImpl.getClassByDelegation(BundleWiringImpl.java:1317)
        at org.apache.felix.framework.BundleWiringImpl.searchImports(BundleWiringImpl.java:1481)
        at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1427)
        at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:72)
        at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1843)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
        ... 18 more

Please note that the framework try to load EventUtil from the iPOJO core bundle.

IMHO this issue comes from the fact that the package org.apache.felix.ipojo.handlers.event is defined in both iPOJO Event Admin Handler bundle and iPOJO Core bundle. 

Kindly find below the results of the inspect command on Event Admin Handler bundle
inspect p c 13
org.apache.felix.ipojo.handler.eventadmin [13] exports packages:
----------------------------------------------------------------
org.apache.felix.ipojo.handlers.event.publisher; version=1.2.0 imported by:
   org.ow2.jonas.mbeans [114]
org.apache.felix.ipojo.handlers.event.subscriber; version=1.2.0 UNUSED


inspect p r 13
org.apache.felix.ipojo.handler.eventadmin [13] imports packages:
----------------------------------------------------------------
org.osgi.framework; version=1.6.0 -> org.apache.felix.framework [0]
org.osgi.service.log; version=1.3.0 -> org.apache.felix.shell [5]
org.apache.felix.ipojo.util; version=1.8.4 -> org.apache.felix.ipojo [8]
org.apache.felix.ipojo.parser; version=1.8.4 -> org.apache.felix.ipojo [8]
org.apache.felix.ipojo; version=1.8.4 -> org.apache.felix.ipojo [8]
org.apache.felix.ipojo.handlers.event; version=1.8.6 -> org.apache.felix.ipojo [8]
org.apache.felix.ipojo.architecture; version=1.8.4 -> org.apache.felix.ipojo [8]
org.apache.felix.ipojo.metadata; version=1.8.4 -> org.apache.felix.ipojo [8]
org.osgi.service.event; version=1.2.0 -> org.apache.felix.eventadmin [12]
org.osgi.service.cm; version=1.3.0 -> org.apache.felix.configadmin [75]

Did I misunderstood something or should I open JIRA issue for this?

Thanks & Best regards,
Loïc 

ipojo tutorial error with javax.swing

Posted by Ales Pavel <ta...@suchdol.net>.
I try pojo tutorial and 
I have problem with error where is problem please?

-----

start file:../spell.services/output/spell.services.jar
start file:../spell.english/output/spell.english.jar
start file:../spell.checker/output/spell.checker.jar
start file:../spell.checker.gui/output/spell.checker.gui.jar

----

org.osgi.framework.BundleException: Unresolved constraint in bundle
spell.checker.gui [11]: package; (package=javax.swing) 

----

thanks


Ales


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


Re: [iPOJO] class loading issue with iPOJO Event Admin Handler 1.8.0 and iPOJO core 1.8.4

Posted by lo...@bull.net.
Hi Clement,

thank you for your answer.
I didn't check trunk until now (my bad, sorry) and indeed as you moved EventUtil to the publisher package it works fine with this version.

So, when can we expect a release of event admin? ;)

Thanks & Regards,
Loïc

-----Clement Escoffier <cl...@gmail.com> a écrit : -----
A : users@felix.apache.org
De : Clement Escoffier <cl...@gmail.com>
Date : 06/12/2012 17:38
Objet : Re: [iPOJO] class loading issue with iPOJO Event Admin Handler 1.8.0 and iPOJO core 1.8.4

Hi,

Try to use the latest event admin from the trunk. 

Regards,

Clement

On 6 déc. 2012, at 17:23, loic.albertin@bull.net wrote:

> Hi Felix users/devs,
> 
> I'm facing an issue when upgrading my iPOJO artifacts to the latest versions.
> I'm using the iPOJO Event Admin Handler 1.8.0 and iPOJO Core 1.8.4.
> When using the Event Admin Handler I get a java.lang.ClassNotFoundException on org.apache.felix.ipojo.handlers.event.EventUtil
> 
> 2012-12-06 16:30:17,709 : LoggerService.log : [ERROR] IPOJO-Extender : An error occurs when analyzing the content or starting the management of 103
> java.lang.NoClassDefFoundError: org/apache/felix/ipojo/handlers/event/EventUtil
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberMetadata.setTopics(EventAdminSubscriberMetadata.java:217)
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberMetadata.<init>(EventAdminSubscriberMetadata.java:148)
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberHandler.__initializeComponentFactory(EventAdminSubscriberHandler.java:143)
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberHandler.initializeComponentFactory(EventAdminSubscriberHandler.java)
>         at org.apache.felix.ipojo.IPojoFactory.computeDescription(IPojoFactory.java:724)
>         at org.apache.felix.ipojo.IPojoFactory.computeFactoryState(IPojoFactory.java:757)
>         at org.apache.felix.ipojo.ComponentFactory.addedService(ComponentFactory.java:414)
>         at org.apache.felix.ipojo.util.Tracker$Tracked.trackAdding(Tracker.java:725)
>         at org.apache.felix.ipojo.util.Tracker$Tracked.trackInitialServices(Tracker.java:610)
>         at org.apache.felix.ipojo.util.Tracker.open(Tracker.java:210)
>         at org.apache.felix.ipojo.ComponentFactory.starting(ComponentFactory.java:262)
>         at org.apache.felix.ipojo.IPojoFactory.start(IPojoFactory.java:605)
>         at org.apache.felix.ipojo.Extender.createAbstractFactory(Extender.java:520)
>         at org.apache.felix.ipojo.Extender.parse(Extender.java:301)
>         at org.apache.felix.ipojo.Extender.startManagementFor(Extender.java:237)
>         at org.apache.felix.ipojo.Extender.access$600(Extender.java:52)
>         at org.apache.felix.ipojo.Extender$CreatorThread.run(Extender.java:769)
>         at java.lang.Thread.run(Thread.java:662)
> Caused by: java.lang.ClassNotFoundException: org.apache.felix.ipojo.handlers.event.EventUtil not found by org.apache.felix.ipojo [8]
>         at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1460)
>         at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:72)
>         at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1843)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>         at org.apache.felix.framework.BundleWiringImpl.getClassByDelegation(BundleWiringImpl.java:1317)
>         at org.apache.felix.framework.BundleWiringImpl.searchImports(BundleWiringImpl.java:1481)
>         at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1427)
>         at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:72)
>         at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1843)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>         ... 18 more
> 
> Please note that the framework try to load EventUtil from the iPOJO core bundle.
> 
> IMHO this issue comes from the fact that the package org.apache.felix.ipojo.handlers.event is defined in both iPOJO Event Admin Handler bundle and iPOJO Core bundle. 
> 
> Kindly find below the results of the inspect command on Event Admin Handler bundle
> inspect p c 13
> org.apache.felix.ipojo.handler.eventadmin [13] exports packages:
> ----------------------------------------------------------------
> org.apache.felix.ipojo.handlers.event.publisher; version=1.2.0 imported by:
>    org.ow2.jonas.mbeans [114]
> org.apache.felix.ipojo.handlers.event.subscriber; version=1.2.0 UNUSED
> 
> 
> inspect p r 13
> org.apache.felix.ipojo.handler.eventadmin [13] imports packages:
> ----------------------------------------------------------------
> org.osgi.framework; version=1.6.0 -> org.apache.felix.framework [0]
> org.osgi.service.log; version=1.3.0 -> org.apache.felix.shell [5]
> org.apache.felix.ipojo.util; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.parser; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.handlers.event; version=1.8.6 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.architecture; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.metadata; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.osgi.service.event; version=1.2.0 -> org.apache.felix.eventadmin [12]
> org.osgi.service.cm; version=1.3.0 -> org.apache.felix.configadmin [75]
> 
> Did I misunderstood something or should I open JIRA issue for this?
> 
> Thanks & Best regards,
> Lo&#8249;c 


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


Re: [iPOJO] class loading issue with iPOJO Event Admin Handler 1.8.0 and iPOJO core 1.8.4

Posted by Clement Escoffier <cl...@gmail.com>.
Hi,

Try to use the latest event admin from the trunk. 

Regards,

Clement

On 6 déc. 2012, at 17:23, loic.albertin@bull.net wrote:

> Hi Felix users/devs,
> 
> I'm facing an issue when upgrading my iPOJO artifacts to the latest versions.
> I'm using the iPOJO Event Admin Handler 1.8.0 and iPOJO Core 1.8.4.
> When using the Event Admin Handler I get a java.lang.ClassNotFoundException on org.apache.felix.ipojo.handlers.event.EventUtil
> 
> 2012-12-06 16:30:17,709 : LoggerService.log : [ERROR] IPOJO-Extender : An error occurs when analyzing the content or starting the management of 103
> java.lang.NoClassDefFoundError: org/apache/felix/ipojo/handlers/event/EventUtil
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberMetadata.setTopics(EventAdminSubscriberMetadata.java:217)
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberMetadata.<init>(EventAdminSubscriberMetadata.java:148)
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberHandler.__initializeComponentFactory(EventAdminSubscriberHandler.java:143)
>         at org.apache.felix.ipojo.handlers.event.subscriber.EventAdminSubscriberHandler.initializeComponentFactory(EventAdminSubscriberHandler.java)
>         at org.apache.felix.ipojo.IPojoFactory.computeDescription(IPojoFactory.java:724)
>         at org.apache.felix.ipojo.IPojoFactory.computeFactoryState(IPojoFactory.java:757)
>         at org.apache.felix.ipojo.ComponentFactory.addedService(ComponentFactory.java:414)
>         at org.apache.felix.ipojo.util.Tracker$Tracked.trackAdding(Tracker.java:725)
>         at org.apache.felix.ipojo.util.Tracker$Tracked.trackInitialServices(Tracker.java:610)
>         at org.apache.felix.ipojo.util.Tracker.open(Tracker.java:210)
>         at org.apache.felix.ipojo.ComponentFactory.starting(ComponentFactory.java:262)
>         at org.apache.felix.ipojo.IPojoFactory.start(IPojoFactory.java:605)
>         at org.apache.felix.ipojo.Extender.createAbstractFactory(Extender.java:520)
>         at org.apache.felix.ipojo.Extender.parse(Extender.java:301)
>         at org.apache.felix.ipojo.Extender.startManagementFor(Extender.java:237)
>         at org.apache.felix.ipojo.Extender.access$600(Extender.java:52)
>         at org.apache.felix.ipojo.Extender$CreatorThread.run(Extender.java:769)
>         at java.lang.Thread.run(Thread.java:662)
> Caused by: java.lang.ClassNotFoundException: org.apache.felix.ipojo.handlers.event.EventUtil not found by org.apache.felix.ipojo [8]
>         at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1460)
>         at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:72)
>         at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1843)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>         at org.apache.felix.framework.BundleWiringImpl.getClassByDelegation(BundleWiringImpl.java:1317)
>         at org.apache.felix.framework.BundleWiringImpl.searchImports(BundleWiringImpl.java:1481)
>         at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1427)
>         at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:72)
>         at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1843)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>         ... 18 more
> 
> Please note that the framework try to load EventUtil from the iPOJO core bundle.
> 
> IMHO this issue comes from the fact that the package org.apache.felix.ipojo.handlers.event is defined in both iPOJO Event Admin Handler bundle and iPOJO Core bundle. 
> 
> Kindly find below the results of the inspect command on Event Admin Handler bundle
> inspect p c 13
> org.apache.felix.ipojo.handler.eventadmin [13] exports packages:
> ----------------------------------------------------------------
> org.apache.felix.ipojo.handlers.event.publisher; version=1.2.0 imported by:
>    org.ow2.jonas.mbeans [114]
> org.apache.felix.ipojo.handlers.event.subscriber; version=1.2.0 UNUSED
> 
> 
> inspect p r 13
> org.apache.felix.ipojo.handler.eventadmin [13] imports packages:
> ----------------------------------------------------------------
> org.osgi.framework; version=1.6.0 -> org.apache.felix.framework [0]
> org.osgi.service.log; version=1.3.0 -> org.apache.felix.shell [5]
> org.apache.felix.ipojo.util; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.parser; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.handlers.event; version=1.8.6 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.architecture; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.apache.felix.ipojo.metadata; version=1.8.4 -> org.apache.felix.ipojo [8]
> org.osgi.service.event; version=1.2.0 -> org.apache.felix.eventadmin [12]
> org.osgi.service.cm; version=1.3.0 -> org.apache.felix.configadmin [75]
> 
> Did I misunderstood something or should I open JIRA issue for this?
> 
> Thanks & Best regards,
> Loïc 


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