Integrated: 8351601: [JMH] test UnixSocketChannelReadWrite failed for 2 threads config

2025-03-27 Thread Volkan Yazici
On Thu, 20 Mar 2025 08:37:45 GMT, Volkan Yazici wrote: > Guards against multi-deletes in `UnixSocketChannelReadWrite`. > > The fix can be verified as follows: > > > make build-microbenchmark > build/linux-x64/jdk/bin/java \ > -jar build/linux-x64/images/test/micro/benchmarks.jar \ > -f 1 -

Re: Relaxing TLS for java.net.http.HttpClient

2025-03-27 Thread Pavel Rappo
Daniel, The only hostnames I can see that SSLParameters accept are SNIServerName. As far as I know, SNIs serve a very different purpose. They are used by the client to tell the server which of the server's multiple names the client is targeting. Could you maybe provide a snippet for me to better u

Re: RFD: Use of ~ (tilde) when considering local and non-local file URLs

2025-03-27 Thread Eirik Bjørsnøs
On Thu, Mar 27, 2025 at 3:03 PM Jaikiran Pai wrote: > Hello Eirik, > > The code in URLJarFile which does that check for "~" seems to have been > introduced for https://bugs.openjdk.org/browse/JDK-4447921. It doesn't > tell why the "~" was necessary. > > In any case, I don't think any kind of clea

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Daniel Fuchs
On Thu, 27 Mar 2025 14:13:22 GMT, Jaikiran Pai wrote: >> The only use of `HttpConnection.id` is for ordering - so that connections >> can be placed in a ConcurrentSkipListSet. So maybe here we should not speak >> of ordering (remove the last sentence in that paragraph) - but I think it >> help

Relaxing TLS for java.net.http.HttpClient

2025-03-27 Thread Pavel Rappo
Hello, I would like java.net.http.HttpClient to send a request to an HTTPS endpoint whose certificate is invalid and cannot be changed. In particular, the certificate's CN is incompatible with the endpoint's domain: javax.net.ssl.SSLHandshakeException: No subject alternative DNS name matching

Re: RFD: Use of ~ (tilde) when considering local and non-local file URLs

2025-03-27 Thread Eirik Bjørsnøs
On Thu, Mar 27, 2025 at 3:03 PM Jaikiran Pai wrote: > Hello Eirik, > > The code in URLJarFile which does that check for "~" seems to have been > introduced for https://bugs.openjdk.org/browse/JDK-4447921. It doesn't > tell why the "~" was necessary. > Similar to the Unix history of using "~" as

Re: Relaxing TLS for java.net.http.HttpClient

2025-03-27 Thread Daniel Fuchs
Hi Pavel, I would recommend fixing the certificate. The only way I know of to disable the verification is to use jdk.internal.httpclient.disableHostnameVerification, and that was introduced for test environment only. I wouldn't recommend using it, except for testing. If you can't fix the certif

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Jaikiran Pai
On Wed, 26 Mar 2025 10:49:06 GMT, Volkan Yazici wrote: >> Adds `HttpResponse::connectionLabel` method that provides an identifier for >> the connection. >> >> **Implementation note:** The feature is facilitated by >> `HttpConnection::label`, which should not be confused with >> `HttpConnectio

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Jaikiran Pai
On Wed, 26 Mar 2025 10:49:06 GMT, Volkan Yazici wrote: >> Adds `HttpResponse::connectionLabel` method that provides an identifier for >> the connection. >> >> **Implementation note:** The feature is facilitated by >> `HttpConnection::label`, which should not be confused with >> `HttpConnectio

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Jaikiran Pai
On Wed, 26 Mar 2025 10:49:06 GMT, Volkan Yazici wrote: >> Adds `HttpResponse::connectionLabel` method that provides an identifier for >> the connection. >> >> **Implementation note:** The feature is facilitated by >> `HttpConnection::label`, which should not be confused with >> `HttpConnectio

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Daniel Fuchs
On Thu, 27 Mar 2025 12:45:07 GMT, Jaikiran Pai wrote: >> Volkan Yazici has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Improve JavaDoc > > src/java.net.http/share/classes/jdk/internal/net/http/HttpConnection.java > line 121: > >> 119:

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Daniel Fuchs
On Thu, 27 Mar 2025 13:02:24 GMT, Jaikiran Pai wrote: >> Volkan Yazici has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Improve JavaDoc > > src/java.net.http/share/classes/jdk/internal/net/http/HttpConnection.java > line 100: > >> 98:

Re: RFD: Use of ~ (tilde) when considering local and non-local file URLs

2025-03-27 Thread Jaikiran Pai
Hello Eirik, The code in URLJarFile which does that check for "~" seems to have been introduced for https://bugs.openjdk.org/browse/JDK-4447921. It doesn't tell why the "~" was necessary. In any case, I don't think any kind of clean up or introducing tests for "~" is worth it, given it's not

Re: RFR: 8350279: HttpClient: Add a new HttpResponse method to identify connections [v4]

2025-03-27 Thread Jaikiran Pai
On Thu, 27 Mar 2025 13:55:34 GMT, Daniel Fuchs wrote: > The only use of HttpConnection.id is for ordering - so that connections can > be placed in a ConcurrentSkipListSet. I wasn't aware of that. Now that you mentioned it, I looked up the code which uses the Set to store these connections. And