On Thu, 26 Mar 2026 12:00:26 GMT, Chen Liang <[email protected]> wrote:

> When running on the windows debug builds, this test displays greatly varying 
> timeouts. In one failing run, the time taken ranges in iterations are 58.388, 
> 22.764, and 63.717 seconds. Another run has 8.814, 38.341, 25.260, 14.678, 
> and 105.368 seconds. I think we can probably adjust this await time by the 
> timeout factor to be more permissive for now.
> 
> @JornVernee Would you be able to diagnose the cause of such perturbations in 
> closing times and find a better solution? Could this be a CI issue?

test/jdk/java/foreign/TestConcurrentClose.java line 76:

> 74:     static final int ITERATIONS = 5;
> 75:     static final int SEGMENT_SIZE = 10_000;
> 76:     static final long MAX_EXECUTOR_WAIT_SECONDS = Utils.adjustTimeout(60);

Just curious, is an actual timeout needed? Could the test just 
try-with-resources as that the close method is invoked on accessExecutor. That 
will shut down the accessor and wait indefinitely for it to terminate. If 
something is broken then the test will timeout, just longer than would be if 
MAX_EXECUTOR_WAIT_SECONDS is used.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/30447#discussion_r2994539188

Reply via email to