Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Launching Equinox Raises Circularity Exception(Embedding Equinox raising Exception. But felix is working properly)
Launching Equinox Raises Circularity Exception [message #516602] Wed, 24 February 2010 14:34 Go to next message
Muhammed Nasir is currently offline Muhammed NasirFriend
Messages: 4
Registered: February 2010
Junior Member
Hi All

I am trying to embed the equinox. My Setup is some thing like this

I have and jar file, say Service.jar. which instantiates equnox. This jar is loaded by exe. (Which has a JVM, Class loader).

But Framework.init() method raises this exception. I have no clue whats happening here.

java.lang.ClassCircularityError: org/eclipse/osgi/framework/internal/protocol/file/Handler

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Class.java:169)

at org.eclipse.osgi.framework.util.SecureAction.forName(SecureA ction.java:343)

at org.eclipse.osgi.framework.internal.protocol.StreamHandlerFa ctory.getBuiltIn(StreamHandlerFactory.java:80)

at org.eclipse.osgi.framework.internal.protocol.StreamHandlerFa ctory.createInternalURLStreamHandler(StreamHandlerFactory.ja va:123)

at org.eclipse.osgi.framework.internal.protocol.StreamHandlerFa ctory.createURLStreamHandler(StreamHandlerFactory.java:110)

at java.net.URL.getURLStreamHandler(URL.java:1106)

at java.net.URL.<init>(URL.java:393)

at java.net.URL.<init>(URL.java:283)

at java.net.URL.<init>(URL.java:306)

at java.io.File.toURL(File.java:623)

at com.sdt.sne.JarDirClassLoader.refreshJarFiles(JarDirClassLoa der.java:110)

at com.sdt.sne.JarDirClassLoader.findClass(JarDirClassLoader.ja va:66)

at java.lang.ClassLoader.loadClass(ClassLoader.java:307)

at java.lang.ClassLoader.loadClass(ClassLoader.java:252)

at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320 )

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Class.java:169)

at org.eclipse.osgi.framework.util.SecureAction.forName(SecureA ction.java:343)

at org.eclipse.osgi.framework.internal.protocol.StreamHandlerFa ctory.getBuiltIn(StreamHandlerFactory.java:80)

at org.eclipse.osgi.framework.internal.protocol.StreamHandlerFa ctory.createInternalURLStreamHandler(StreamHandlerFactory.ja va:123)

at org.eclipse.osgi.framework.internal.protocol.StreamHandlerFa ctory.createURLStreamHandler(StreamHandlerFactory.java:110)

at java.net.URL.getURLStreamHandler(URL.java:1106)

at java.net.URL.<init>(URL.java:393)

at java.net.URL.<init>(URL.java:283)

at java.net.URL.<init>(URL.java:306)

at java.io.File.toURL(File.java:623)

at com.sdt.sne.JarDirClassLoader.refreshJarFiles(JarDirClassLoa der.java:110)

at com.sdt.sne.JarDirClassLoader.findClass(JarDirClassLoader.ja va:66)

at java.lang.ClassLoader.loadClass(ClassLoader.java:307)

at java.lang.ClassLoader.loadClass(ClassLoader.java:252)

at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320 )

at org.eclipse.osgi.framework.internal.core.Framework.installCo ntentHandlerFactory(Framework.java:1459)

at org.eclipse.osgi.framework.internal.core.Framework.initializ e(Framework.java:231)

at org.eclipse.osgi.framework.internal.core.Framework.<init>(Framework.java:157)

at org.eclipse.osgi.framework.internal.core.EquinoxLauncher.int ernalInit(EquinoxLauncher.java:68)

at org.eclipse.osgi.framework.internal.core.EquinoxLauncher.ini t(EquinoxLauncher.java:38)

at org.eclipse.osgi.launch.Equinox.init(Equinox.java:89)

at demo.Service.onCreate(Service.java:45)

at com.sdt.sne.Service.onBasicCreate(Service.java:209)

at com.sdt.sne.eoa.passive.PassiveService.onBasicCreate(Passive Service.java:167)

at demo.Service.onBasicCreate(Service.java:97)

at com.sdt.sne.Service.onCreate0(Service.java:216)

at com.sdt.sne.Service.create0(Native Method)

at com.sdt.sne.Service.create(Service.java:781)

Re: Launching Equinox Raises Circularity Exception [message #516618 is a reply to message #516602] Wed, 24 February 2010 15:35 Go to previous messageGo to next message
Thomas Watson is currently offline Thomas WatsonFriend
Messages: 437
Registered: July 2009
Senior Member
Could you please open a bug on this. It appears that the URL handler factory was replaced by the framework which flushed the "file" protocol from the VM. So the next time a class load is done we need to get the "file" protocol again. This causes a circularity issue because we keep trying to load the same class for the file protocol over and over.

I think we need to prevent recursive calls into the handler factory for the same protocol handler.
Re: Launching Equinox Raises Circularity Exception [message #516678 is a reply to message #516618] Wed, 24 February 2010 18:28 Go to previous messageGo to next message
Muhammed Nasir is currently offline Muhammed NasirFriend
Messages: 4
Registered: February 2010
Junior Member
How can i proceed now? Is there any work around? I am not able to Launch equinox.
Re: Launching Equinox Raises Circularity Exception [message #516689 is a reply to message #516678] Wed, 24 February 2010 19:05 Go to previous messageGo to next message
Thomas Watson is currently offline Thomas WatsonFriend
Messages: 437
Registered: July 2009
Senior Member
You will need to open a bug against Equinox->Framework at https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Equinox to get a fix. I don't see a way around the issue at the moment. When you open the bug report it would help if you provide a testcase to reproduce. Perhaps we can see if there is any workaround.
Re: Launching Equinox Raises Circularity Exception [message #516760 is a reply to message #516689] Thu, 25 February 2010 01:17 Go to previous message
Muhammed Nasir is currently offline Muhammed NasirFriend
Messages: 4
Registered: February 2010
Junior Member
https://bugs.eclipse.org/bugs/show_bug.cgi?id=303842 Defect Raised. Pls let me know if there are any work arounds...
Previous Topic:Bundle resolution error messages
Next Topic:Is it not possible to instantiate Equinox in C++ thread?
Goto Forum:
  


Current Time: Sat Nov 29 07:39:42 GMT 2014

Powered by FUDForum. Page generated in 0.08824 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software