RFR: 8330523: Reduce runtime and improve efficiency of KeepAliveTest [v3]

Christoph Langer clanger at openjdk.org
Wed Apr 24 13:32:31 UTC 2024


On Wed, 24 Apr 2024 10:11:03 GMT, Daniel Jeliński <djelinski at openjdk.org> wrote:

>> Christoph Langer has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
>> 
>>  - Simplify the test further
>>  - Merge branch 'master' into JDK-8330523
>>  - Small further cleanup
>>  - JDK-8330523
>
> test/jdk/sun/net/www/http/HttpClient/KeepAliveTest.java line 112:
> 
>> 110:     private volatile boolean isProxySet;
>> 111: 
>> 112:     private CountDownLatch serverLatch = new CountDownLatch(1);
> 
> CountDownLatch is not reusable; consider using a Semaphore here

Yes, but there's always new instance per test. One could certainly change it to use a global static semaphore...

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18817#discussion_r1577895205


More information about the net-dev mailing list