Eclipse hanging

8 views
Skip to first unread message

Tom Davies

unread,
May 15, 2007, 7:03:04 PM5/15/07
to CAL Language Discussion
I've got my Eclipse workspace into a state where it hangs on startup,
while rebuilding the workspace. I'm using 3.2.2 M20070212-1330 and the
1.4 CAL plugin.

This is the message from the log file:

!SESSION 2007-05-16 07:51:19.223
-----------------------------------------------
eclipse.buildId=M20070212-1330
java.version=1.5.0_07
java.vendor=Apple Computer, Inc.
BootLoader constants: OS=macosx, ARCH=x86, WS=carbon, NL=en_US
Framework arguments: -keyring /Users/tomd/.eclipse_keyring -
showlocation
Command-line arguments: -os macosx -ws carbon -keyring /Users/
tomd/.eclipse_keyring -consoleLog -showlocation

!ENTRY org.eclipse.osgi 4 0 2007-05-16 07:52:26.887
!MESSAGE While loading class
"org.openquark.cal.eclipse.core.CALModelManager$3$1", thread
"Worker-4" timed out waiting (5000ms) for thread "Worker-5" to finish
starting bundle "org.openquark.cal.eclipse.core". To avoid deadlock,
thread "Worker-4" is proceeding but
"org.openquark.cal.eclipse.core.CALModelManager$3$1" may not be fully
initialized.
!STACK 0
java.lang.Exception: Generated exception.
at
org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.preFindLocalClass(EclipseLazyStarter.java:
77)
at
org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:
412)
at
org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:
189)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findLocalClass(BundleLoader.java:
334)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:
386)
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findClass(BundleLoader.java:
347)
at
org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:
83)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at org.openquark.cal.eclipse.core.CALModelManager
$3.run(CALModelManager.java:665)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:58)

Let me know if I can provide any other information which would help
(e.g. my .metadata directory and projects?)

Tom

Edward

unread,
May 15, 2007, 9:38:19 PM5/15/07
to CAL Language Discussion
Hi Tom,
Thanks for the bug, and especially for providing salient details.
Based on the stack trace, I have a suspicion that it might not really
be our fault, though it may (or may not) be something for which we can
code a workaround.
I haven't done extensive testing on the Mac though -- this is
something that we'll try.

Do you mind telling me:
- If you start Eclipse again, does the error go away?
- Does the error happen regularly? For instance, can you make it
happen if you start Eclipse a few times?

Of course, reproduction steps would be nice if you have them.

Thanks,
- Edward

Tom Davies

unread,
May 17, 2007, 7:36:09 AM5/17/07
to CAL Language Discussion

On May 16, 11:38 am, Edward <edward....@gmail.com> wrote:

> Do you mind telling me:
> - If you start Eclipse again, does the error go away?

No -- it happens every time.

> - Does the error happen regularly? For instance, can you make it
> happen if you start Eclipse a few times?

I can use a workspace happily for hours, with many restarts of
Eclipse. Then something happens and that workspace is no good any
more. This has happened twice.

I can email you my workspace if you like -- it's only 6MB as a tgz

Regards,
Tom

Edward

unread,
May 17, 2007, 1:10:13 PM5/17/07
to CAL Language Discussion
Yes, please provide a copy of your workspace in the state where it's
hung Eclipse.
I'll try to reproduce the problem.

Edward

unread,
May 18, 2007, 9:28:07 PM5/18/07
to CAL Language Discussion
It appears to be a manifestation of this bug in Eclipse:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=106812

When the CAL Eclipse Core plugin starts up, some classloading is
taking too long. This causes activation of the plugin to timeout,
followed by a general badness.

Apart from voting for this bug on Eclipse, I'll try to code around the
problem, as it seems pretty nasty.

Thanks,
- Edward

Tom Davies

unread,
May 22, 2007, 2:33:00 AM5/22/07
to CAL Language Discussion
I've (temporarily?) fixed the problem by downloading 3.3RC1, pointing
it at my old workspace, and then reinstalling the CAL plugin...

Tom

Edward

unread,
May 22, 2007, 3:47:31 PM5/22/07
to CAL Language Discussion
Hi Tom,
I wasn't able to reproduce the problem, as it's a threading / timing
issue.
But the code and stack trace provide a lot of hints -- I've checked in
something which should work around the problem.
The fix will be available in the next release.

I had a look at the suspect class in Eclipse 3.3 RC1
(org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter) -- the
changes here include moving the timeout to a different part of the
code (and a different part of the loading sequence). Hopefully that
makes the problem completely go away -- but please let me know if
you're still having problems.

Thanks,
- Edward

Tom Davies

unread,
Jul 16, 2007, 9:50:05 PM7/16/07
to CAL Language Discussion
Hi Edward,

I'm having this problem with Quark 1.5.0 and Eclipse 3.3 -- but I
think it may now be a different problem.

The hanging thread looks like this:

"Worker-3" prio=5 tid=0x0113cec0 nid=0x19cb600 runnable
[0xb092d000..0xb092ed10]
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1751)
- locked <0x24bb44b8> (a java.util.Vector)
- locked <0x24bb44d0> (a java.util.Vector)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1668)
at java.lang.Runtime.loadLibrary0(Runtime.java:822)
- locked <0x24bb3800> (a java.lang.Runtime)
at java.lang.System.loadLibrary(System.java:992)
at
sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:50)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Toolkit.loadLibraries(Toolkit.java:1509)
at java.awt.Toolkit.<clinit>(Toolkit.java:1530)
at java.awt.Color.<clinit>(Color.java:250)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:164)
at
org.openquark.cal.eclipse.core.CALEclipseCorePlugin.start(CALEclipseCorePlugin.java:
107)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl
$2.run(BundleContextImpl.java:999)

So it seems to be hanging when it tries to construct a Color instance,
which causes awt to be initialized.

I don't understand the problem, but it has been mentioned here:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=67384#c29

What I discovered I needed to do was to give eclipse the -
Dapple.awt.usingSWT=true argument.

See https://bugs.eclipse.org/bugs/show_bug.cgi?id=67384#c127

I haven't figured out if this causes any other problems, so you might
want to look at not serialising Color objects?

Tom

Tom

Edward

unread,
Jul 17, 2007, 1:30:18 PM7/17/07
to CAL Language Discussion
(This discussion is continued on the thread titled: "Eclipse hanging
on OS X")

Edward

unread,
Jul 17, 2007, 1:35:22 PM7/17/07
to CAL Language Discussion
(Note: this discussion has been continued on the thread titled
Reply all
Reply to author
Forward
0 new messages