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 20182 - ConcurrentModificationException fired unreasonably
Summary: ConcurrentModificationException fired unreasonably
Status: VERIFIED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 3.x
Hardware: PC Linux
: P2 blocker (vote)
Assignee: Daniel Prusa
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-02-05 18:35 UTC by Svata Dedic
Modified: 2005-07-27 08:26 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Exception's stacktrace (1.54 KB, text/plain)
2002-02-05 18:35 UTC, Svata Dedic
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Svata Dedic 2002-02-05 18:35:20 UTC
I've run a code, which finds or instantiates a package in one thread and fills
it with instances in another one. To my surprise, code which creates instances
within (already createad) package extent interfered with the code which was
iterating  through package extents in the Repository trying to find a specific
extent.
The operations are quite unrelated (to a client), so the ConcurrentModEx seems
more like implementation/design bug.
Attaching a stacktrace.
Comment 1 Svata Dedic 2002-02-05 18:36:00 UTC
Created attachment 4582 [details]
Exception's stacktrace
Comment 2 Svata Dedic 2002-02-05 18:49:17 UTC
During discussion with Martin about this issue an interesting thing
came out:
Suppose you'll have two classes C connected by an association A in the
metamodel. Now suppose there are instances of C (a, b, c, d, e)
connected as a -> b and c -> d. If the client code now retrieves link
collection with endpoint "c" trying to iterate through the collection
and some other thread is changing a -> b to e.g. a->e, the iterating
client will get the ConcurrentModEx. This is quite unusual and
unexpected for the client, since nothing has interfered with the link
set being iterated.
Comment 3 Daniel Prusa 2002-04-02 10:59:09 UTC
Fixed in main trunk.
Comment 4 Jiri Prox 2005-07-27 08:26:28 UTC
quite for too long, verified