RFR: 8369920: HttpClient QuicSelectorThread could be a VirtualThread [v4]

Daniel Fuchs dfuchs at openjdk.org
Tue Nov 4 15:16:15 UTC 2025


On Mon, 3 Nov 2025 20:24:59 GMT, Volkan Yazici <vyazici at openjdk.org> wrote:

>> Daniel Fuchs has updated the pull request incrementally with three additional commits since the last revision:
>> 
>>  - Apply suggestion from @vy
>>    
>>    Co-authored-by: Volkan Yazıcı <volkan.yazici at oracle.com>
>>  - Apply suggestion from @vy
>>    
>>    Co-authored-by: Volkan Yazıcı <volkan.yazici at oracle.com>
>>  - Update the test to match the new property name
>
> src/java.net.http/share/classes/jdk/internal/net/http/quic/QuicSelector.java line 510:
> 
>> 508:     }
>> 509: 
>> 510:     private record QuicSelectorThread(Thread thread) {
> 
> AFAICS, all methods – `start()`, `join()`, `ofPlatform()`, `ofVirtual()`, and `of()` – can be `private`.

You're not wrong, but I prefer to keep them package to distinguish betwen methods that should only be called from with the record class itself as opposed to methods that are designed to be called from the enclosing class, or other classes in the nest.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27827#discussion_r2490903516


More information about the net-dev mailing list