Please use the Apache issue tracking system for new NetBeans issues ( !!
Bug 188298 - infinite loop causes unusable IDE after opening two suites projects
infinite loop causes unusable IDE after opening two suites projects
Product: projects
Classification: Unclassified
Component: Generic Infrastructure
All All
: P2 (vote)
: 7.0
Assigned To: Jesse Glick
Depends on:
  Show dependency treegraph
Reported: 2010-07-02 06:33 UTC by Vladimir Voskresensky
Modified: 2010-07-08 03:26 UTC (History)
0 users

See Also:
Issue Type: DEFECT

thread dump demonstrating infinite loop in WeakHashMap.put (20.13 KB, text/plain)
2010-07-02 06:33 UTC, Vladimir Voskresensky

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Voskresensky 2010-07-02 06:33:38 UTC
Created attachment 100555 [details]
thread dump demonstrating infinite loop in WeakHashMap.put

Selected 2 suites projects in Open Project dialog.
after that modal dialog "Opening Projects" stands forever, projects are not opened => no way to work with IDE without killing it.

  Product Version         = NetBeans IDE Dev (Build 100702-a1cb2df9a24a) (#a1cb2df9a24a)
  Operating System        = SunOS version 5.10 running on x86
  Java; VM; Vendor        = 1.6.0_14; Java HotSpot(TM) Client VM 14.0-b16; Sun Microsystems Inc.
  Runtime                 = Java(TM) SE Runtime Environment 1.6.0_14-b08
  Java Home               = /usr/jdk/instances/jdk1.6.0_14/jre

I'll attach thread dump demonstrating problem of infinite loop in WeakHashMap.put
Comment 1 Jesse Glick 2010-07-02 13:43:52 UTC
I'm afraid I can't reproduce your problem, and the thread dump does not really tell me anything other than there is a problem in WeakHashMap.
Comment 2 Vladimir Voskresensky 2010-07-05 07:41:54 UTC
There is no problems in WeakHashMap but it is not thread safe.
Please, check if you correctly access proj2Factory collection. 
The problem is that you can not call even 2 map.get() without sync from different threads (because of expungeStaleEntries which modifies internal structures), so i.e. 2 accesses under org.openide.util.Mutex.readAccess can corrupt map

Of course it's difficult to reproduce, but have to reopen, because thread dump 100% indicates incorrect synchronization in code
Comment 3 Vladimir Voskresensky 2010-07-07 09:11:31 UTC
happened again
Comment 4 Jesse Glick 2010-07-07 15:12:45 UTC
core-main #68f45dee0e79
Comment 5 Quality Engineering 2010-07-08 03:26:54 UTC
Integrated into 'main-golden', will be available in build *201007080001* on (upload may still be in progress)
User: Jesse Glick <>
Log: #188298: infinite loop causes unusable IDE after opening two suites projects

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo