RFR: 8351038: ConcurrentModificationException in EventType constructor

Andy Goryachev angorya at openjdk.org
Wed Mar 5 19:41:47 UTC 2025


- synchronized `EventType::register()` method
- simplified internal constructor which is only used for `EventType.ROOT`

There should negligent impact on performance when `EventTypes` are created in the FX Application Thread.

There might be a distant potential for a deadlock if the application wraps code that creates `EventTypes` in a block synchronized on a different object.

-------------

Commit messages:
 - test
 - synchronized

Changes: https://git.openjdk.org/jfx/pull/1729/files
  Webrev: https://webrevs.openjdk.org/?repo=jfx&pr=1729&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8351038
  Stats: 82 lines in 2 files changed: 64 ins; 13 del; 5 mod
  Patch: https://git.openjdk.org/jfx/pull/1729.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/1729/head:pull/1729

PR: https://git.openjdk.org/jfx/pull/1729


More information about the openjfx-dev mailing list