This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 12136 - Race Condition in DataObjectPool.Validator.removeInvalidObject
Summary: Race Condition in DataObjectPool.Validator.removeInvalidObject
Status: CLOSED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Data Systems (show other bugs)
Version: 3.x
Hardware: PC Windows 3.1/NT
: P3 blocker (vote)
Assignee: phamernik
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-05-11 23:31 UTC by _ gfink
Modified: 2008-12-23 11:29 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
stacktrace of blocked Automount thread (2.11 KB, text/plain)
2002-01-25 17:32 UTC, _ rkubacki
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ gfink 2001-05-11 23:31:58 UTC
Using a FFJ EA build 5_10 mount a web module with a few jar files in
web-inf/lib.  Using the Filesystem Customize dialog, see various additional
filesystems mounted automatically.  Then unmount the web module.  A significant
percentage of the time, the additional filesystems aren't unmounted
automatically. 

The reason:
WebContextObject is the data object for the root of the filesystem when it is a
web module.  WebContextObject.dispose() unmounts the additional filesystems by
using the RequestProcessor.  If no delay is given to the RequestProcessor, 
when the first filesystem is automatically removed, DataObjectPool.goOn()
returns false, and DataObjectPool.Validator.removeInvalidObject() is called
again.  Unfortunately, the fileobjects from the WebContextObject are still in
the file Set, so dispose() is called a second time (and potentially an infinite
number of times).  (Note: The dispose() method on WebInfObject also disposes
WebContextObject, so this can also set off the loop).

The workaround being considered for the web module is to set a 5-second delay
on the RequestProcessor.post() call for the automatic filesystem unmounting.
Comment 1 akemr 2001-07-09 15:35:10 UTC
Reassign to proper address.
Comment 2 akemr 2001-09-04 06:58:17 UTC
Reassign to Vita
Comment 3 Vitezslav Stejskal 2001-09-21 13:23:02 UTC
Moving to data systems
Comment 4 Jan Chalupa 2001-11-27 13:02:33 UTC
Target milestone -> 3.3.1.
Comment 5 Vitezslav Stejskal 2001-11-30 17:56:03 UTC
Reassigning to the new cutodian of Data Systems.
Comment 6 rmatous 2001-12-13 13:26:59 UTC
Fixed in release33 (DataObjectPool.Validator: 1.53.8.1). I found 
problem in validator: there is optimization that should merge 
requests for revalidating. But once revalidated DataObject should not 
be part of merge and revalidated again and again. 
Comment 7 Jan Zajicek 2001-12-14 13:00:09 UTC
George please can you verify fix of this issue? Thanks.
Comment 8 _ rkubacki 2002-01-25 17:31:28 UTC
Really we can remove the delay. We still can't call
Repository.removeFileSystem directly from DataObject.dispose(). The
mounting is blocked in that case (see atached stack trace). Is that OK?
Comment 9 _ rkubacki 2002-01-25 17:32:43 UTC
Created attachment 4429 [details]
stacktrace of blocked Automount thread
Comment 10 pzajac 2003-06-11 14:50:43 UTC
seems fine 
Comment 11 Quality Engineering 2003-07-01 16:22:02 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.