On Thu, 20 Nov 2025 09:58:48 GMT, Daniel Fuchs <[email protected]> wrote:

>> src/java.net.http/share/classes/jdk/internal/net/http/HttpClientImpl.java 
>> line 131:
>> 
>>> 129: 
>>> 130:     static final UseVTForSelector USE_VT_FOR_SELECTOR =
>>> 131:         
>>> Utils.useVTForSelector("jdk.internal.httpclient.tcp.selector.useVirtualThreads",
>>>  "default");
>> 
>> Hello Daniel, I vaguely remember we discussed whether or not to use a value 
>> called "default" for this property. But I don't remember what we decided. 
>> Looking at this now, I am wondering whether we should just do something like:
>> 
>> System.getProperty("jdk.internal.httpclient.tcp.selector.useVirtualThreads", 
>> "true")
>> 
>> to keep it simple?
>
> For tcp we only need true/false - but for quic we have a default behavior 
> which depends on the platform. I decided to keep "always/never/default" for 
> both properties for consistency. Let me think about it. I am not sure if that 
> change (true/false for quic too) should be made in this PR.

[JDK-8369920] delivered in #27827 introduced


String useVtForSelector =
        
System.getProperty("jdk.internal.httpclient.quic.selector.useVirtualThreads", 
"default");


26 window is closing, and I'm inclined to keep the properties aligned, that is, 
employ the always-never-default trichotomy. I can see the angle of @jaikiran; 
if a simpler true-false dichotomy fits the bill, let's go for it. But I'd 
appreciate it in a follow-up PR _and_ for both properties.

[JDK-8369920]: https://bugs.openjdk.org/browse/JDK-8369920

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

PR Review Comment: https://git.openjdk.org/jdk/pull/28395#discussion_r2556108874

Reply via email to