Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug 74] fixed concurrentModificationExceptions for Synchronized EList's #204

Merged
merged 1 commit into from Dec 21, 2015

Conversation

@fgdrf
Copy link
Contributor

@fgdrf fgdrf commented Dec 18, 2015

EMF isn't thread safe and therefor its required to synchronize read and writes. Write access in uDig is synchroinzed using a Lock Object. But using an Iterator to read Elements of the list were not sychronized correctly.

In addition the javadoc indicated that users should synchronize on the list itself. If implemented this way synchronization is not consistent because the monitor is based on two different objects, the EList and the Lock Object. In result it causes ConcurrentModificationException's.

The pull request:

  • fixes Sychronized-EList
  • updates javadocs
  • adds two test cases

Many thanks to Erdal Karaca (@erdalkaraca) for the pair programming session!

AlsoBy: Erdal Karaca <erdal.karaca.de@googlemail.com>

Signed-off-by: Frank Gasdorf <fgdrf@users.sourceforge.net>
@fgdrf
Copy link
Contributor Author

@fgdrf fgdrf commented Dec 18, 2015

Correct issue at LocationTech bugzilla instance : https://locationtech.org/bugs/show_bug.cgi?id=74

@fgdrf
Copy link
Contributor Author

@fgdrf fgdrf commented Dec 20, 2015

fgdrf added a commit that referenced this pull request Dec 21, 2015
[Bug 74] fixed ConcurrentModificationExceptions for Synchronized EList's
@fgdrf fgdrf merged commit 2e6bc78 into locationtech:master Dec 21, 2015
1 check passed
1 check passed
ip-validation
Details
@fgdrf fgdrf deleted the fgdrf:sync-elist-concurrent branch Dec 21, 2015
@fgdrf fgdrf added this to the uDig-2.0.0 milestone Mar 18, 2017
@fgdrf fgdrf added the bug label Sep 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants