> After [JDK-8308232](https://bugs.openjdk.org/browse/JDK-8308232), both the 
> test and the debuggee shared the same waittime of 5 minutes. The test would 
> wait up to 5 minutes for the expected prompt, but the debuggee would also in 
> some cases wait 5 minutes before generating the prompt, which sometimes was 
> just a bit too late. Before 
> [JDK-8308232](https://bugs.openjdk.org/browse/JDK-8308232), the debuggee 
> would wait at most 2 minutes before generating the prompt, so it was always 
> generated in time.
> 
> The main issue is that after the while loop checks that there are still 
> uninterrupted threads remaining, the last of the threads is interrupted 
> before the wait() call is made. This means wait() won't return until it times 
> out, and by then it is too late, and the test side has already timed out 
> waiting for the prompt.
> 
> For details see 
> https://bugs.openjdk.org/browse/JDK-8310551?focusedCommentId=14594838&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-14594838

Chris Plummer has updated the pull request incrementally with one additional 
commit since the last revision:

  Different approach to fix. Widen synchronized block so there is no need to 
refetch the notInterrupted count.

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/14817/files
  - new: https://git.openjdk.org/jdk/pull/14817/files/87b7bc32..41325e59

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=14817&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=14817&range=00-01

  Stats: 8 lines in 1 file changed: 0 ins; 5 del; 3 mod
  Patch: https://git.openjdk.org/jdk/pull/14817.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/14817/head:pull/14817

PR: https://git.openjdk.org/jdk/pull/14817

Reply via email to