Fabric Profile problem

80 views
Skip to first unread message

Christian H

unread,
Aug 2, 2012, 6:32:28 PM8/2/12
to fusef...@googlegroups.com
Hello,
Been working with the fuse fabric environment for a bit now, trying to create a profile based on a parent and having some trouble.

I have a very basic ReST service that I want to deploy. If I create a cxf profile container and manually add my two bundles (interface and impl) with the file:/ installer and start them they work as advertised. BUT when I create a profile based on the cxf as a parent and include my bundles into the profile and start the container, I get an error in the log:

...

Caused by: java.lang.NoClassDefFoundError: Could not initialize class org.apache.cxf.jaxrs.utils.JAXRSUtils...
...
41 more

Then if I uninstall the bundles and re-install them from the console, they cause a similar problem and the container is still not deploying my ReST service:

Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException: com.sun.ws.rs.ext.RuntimeDelegateImpl not found by org.fusesource.fabric.fabric-agent [63]
                at javax.ws.rs.ext.RuntimeDelegate.findDelegate(RuntimeDelegate.java:122)
                at javax.ws.rs.ext.RuntimeDelegate.getInstance(RuntimeDelegate.java:91)
                at javax.ws.rs.core.MediaType.<clinit>(MediaType.java:44)
                ... 48 more
Caused by: java.lang.ClassNotFoundException: com.sun.ws.rs.ext.RuntimeDelegateImpl not found by org.fusesource.fabric.fabric-agent [63]
                at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1467)
                at org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:73)
                at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1850)
                at java.lang.ClassLoader.loadClass(ClassLoader.java:356)[:1.7.0_05]
                at javax.ws.rs.ext.FactoryFinder.newInstance(FactoryFinder.java:37)
                at javax.ws.rs.ext.FactoryFinder.find(FactoryFinder.java:143)
                at javax.ws.rs.ext.RuntimeDelegate.findDelegate(RuntimeDelegate.java:105)

If I remove the two bundles out of my profile and restart the container, it works if I manually install the bundles and start them.

How does a bundle differ in being deployed in a profile vs manually? The bundles end up as start-level 60.

Thanks,
--Christian

Ioannis Canellos

unread,
Aug 16, 2012, 12:31:45 PM8/16/12
to fusef...@googlegroups.com
The fact that your code is using the classloader of the fabric-agent in order to load classes, makes me think that it has some kind of class loading issues.

--
Ioannis Canellos

Twitter: iocanel


Reply all
Reply to author
Forward
0 new messages