Community
Participate
Working Groups
I was using code assist in the New Class dialog to get the package for a superclass. When doing so a deadlock occured (using build I20040422). I will attach the stacktrace.
Created attachment 9963 [details] Stack trace
Both blocked threads are waiting for a look owned by the Java indexer: ThreadName=main(0x805247c) Status=Blocked Monitor=0x809e3a8 (Object monitor for org/eclipse/jdt/internal/core/search/indexing/IndexManager @ 0x4249a408) Count=1 Owner=Java indexing(0x831cd00) However the Java Indexer thread doesn't seem to own a look (at least from the VM dump). Both code ends are owned be JDT/Core. Philippe is there anything special we can do in JDT/UI (look ordering). I looked into it and it doesn't seem that we are aquiring and special looks except a synchronized on the ICodeSelect we call codeSelect on.
The 2 waiting threads appear to be waiting for the monitor for the IndexManager since they're calling getIndex(), which is a synchronized method... but there is no thread in the trace which shows the IndexManager doing anything.
Closing... talked to McQ & we both agree that this must be a VM problem. For the 2 threads to be waiting on the monitor of the IndexManager, there must be a thread in which the IndexManager is doing something. Without it just looks like the VM forgot to release one of the 2 waiting threads.