[jdk11u-dev] RFR: 8272966: test/jdk/java/awt/Robot/FlushCurrentEvent.java fails by timeout
Sergey Bylokhov
serb at openjdk.java.net
Thu Sep 2 22:51:44 UTC 2021
The test case backported by the [JDK-8267722](https://bugs.openjdk.java.net/browse/JDK-8267722) is too strict for jdk11. It uses the `Robot.delay()` method which is `synchronised` in jdk11 and this caused a deadlock.
Main thread: `synchronized robot.waitForIdle()` - > trying to synchronously execute the code on EDT
EDT: trying to call `synchronized Robot.delay()`
The synchronized keyword was removed by the [JDK-8210231](https://bugs.openjdk.java.net/browse/JDK-8210231) in JDK15 and it cannot be backported due to compatibility reasons.
The solution is to relax this part of the test which does not affect its ability to verify the fix for JDK-8196100
-------------
Commit messages:
- Update FlushCurrentEvent.java
Changes: https://git.openjdk.java.net/jdk11u-dev/pull/309/files
Webrev: https://webrevs.openjdk.java.net/?repo=jdk11u-dev&pr=309&range=00
Issue: https://bugs.openjdk.java.net/browse/JDK-8272966
Stats: 9 lines in 1 file changed: 7 ins; 0 del; 2 mod
Patch: https://git.openjdk.java.net/jdk11u-dev/pull/309.diff
Fetch: git fetch https://git.openjdk.java.net/jdk11u-dev pull/309/head:pull/309
PR: https://git.openjdk.java.net/jdk11u-dev/pull/309
More information about the jdk-updates-dev
mailing list