Re: RFR: 8286962: java/net/httpclient/ServerCloseTest.java failed once with ConnectException

2022-06-14 Thread Daniel Fuchs
On Tue, 14 Jun 2022 15:20:28 GMT, Conor Cleary wrote: > **Issue** > A failure in this test was observed whereby an unexpected connection from a > client that was not created by the test caused the test to unsucessfully > complete. > > **Solution** > When a connection is accepted by the Server

Re: HTTP/308 handling in HttpURLConnection

2022-06-10 Thread Daniel Fuchs
Hi Robert, On 10/06/2022 11:54, Robert Stupp wrote: Does anyone recall why HTTP/308 was not implemented that time? I suspect that HTTP/308 was just not a thing 14/15 years ago, but no clue whether it’s just not been implemented all the time or whether there was a reason to not handle it at al

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100 [v4]

2022-06-09 Thread Daniel Fuchs
On Thu, 9 Jun 2022 13:06:34 GMT, Conor Cleary wrote: >> **Issue** >> It was observed that when the httpclient sends a POST request with the >> `Expect: 100 Continue` header set and the server replies with a response >> code `417 Expectation Failed` that the httpclient hangs indefinitely when >

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100 [v3]

2022-06-09 Thread Daniel Fuchs
On Thu, 9 Jun 2022 12:05:43 GMT, Jaikiran Pai wrote: >> Its not needed for a GET request as the client is not sending a body in that >> case. In this test the GET serves only to complete the HTTP/2 upgrade before >> testing with a POST request. > > From what I understand, the HTTP version in th

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100 [v2]

2022-06-09 Thread Daniel Fuchs
On Thu, 9 Jun 2022 11:26:52 GMT, Jaikiran Pai wrote: >> src/java.net.http/share/classes/jdk/internal/net/http/Stream.java line 308: >> >>> 306: // Have to mark request as sent, due to no request body being >>> sent >>> 307: // in the event of a 417 Expectation Failed >>> 308:

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100 [v2]

2022-06-09 Thread Daniel Fuchs
On Thu, 9 Jun 2022 11:10:11 GMT, Jaikiran Pai wrote: >> Conor Cleary has updated the pull request incrementally with one additional >> commit since the last revision: >> >> 8286171: Added teardown method and comments > > src/java.net.http/share/classes/jdk/internal/net/http/Http1Exchange.java

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100 [v2]

2022-06-09 Thread Daniel Fuchs
On Thu, 9 Jun 2022 10:31:31 GMT, Conor Cleary wrote: >> **Issue** >> It was observed that when the httpclient sends a POST request with the >> `Expect: 100 Continue` header set and the server replies with a response >> code `417 Expectation Failed` that the httpclient hangs indefinitely when >

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100

2022-06-09 Thread Daniel Fuchs
On Wed, 8 Jun 2022 18:29:10 GMT, Conor Cleary wrote: > **Issue** > It was observed that when the httpclient sends a POST request with the > `Expect: 100 Continue` header set and the server replies with a response code > `417 Expectation Failed` that the httpclient hangs indefinitely when the >

Re: RFR: 8286171: HttpClient/2 : Expect:100-Continue blocks indefinitely when response is not 100

2022-06-09 Thread Daniel Fuchs
On Wed, 8 Jun 2022 18:29:10 GMT, Conor Cleary wrote: > **Issue** > It was observed that when the httpclient sends a POST request with the > `Expect: 100 Continue` header set and the server replies with a response code > `417 Expectation Failed` that the httpclient hangs indefinitely when the >

Re: RFR: 8276798: HttpURLConnection sends invalid HTTP request

2022-06-08 Thread Daniel Fuchs
On Mon, 6 Jun 2022 09:43:50 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which proposes to fix > https://bugs.openjdk.java.net/browse/JDK-8276798? > > `sun.net.www.protocol.http.HttpURLConnection` has a (private) `writeRequests` > method. This method is responsible for c

Re: RFR: 8284780: Need methods to create pre-sized HashSet and LinkedHashSet [v17]

2022-06-02 Thread Daniel Fuchs
On Fri, 27 May 2022 18:40:32 GMT, XenoAmess wrote: >> as title. > > XenoAmess has updated the pull request incrementally with one additional > commit since the last revision: > > do it as naotoj said Changes to `net` and `http` look good. - Marked as reviewed by dfuchs (Reviewe

Re: RFR: 8272702: Resolving URI relative path with no / may lead to incorrect toString

2022-06-01 Thread Daniel Fuchs
On Thu, 26 May 2022 09:18:56 GMT, KIRIYAMA Takuya wrote: > Consider an authority component without trailing "/" as a base URI. When > resolving a relative path against this base URI, the resulting URI is a > concatenated URI without "/". > This behaviour should be fixed, which is rationalized b

Re: RFR: 8287390: Cleanup Map usage in AuthenticationInfo.requestAuthentication

2022-06-01 Thread Daniel Fuchs
On Sat, 30 Apr 2022 10:17:43 GMT, Andrey Turbanov wrote: > `AuthenticationInfo.requestAuthentication` uses separate `HashMap`'s `get` > +`put` calls. > > https://github.com/openjdk/jdk/blob/176bb23de18d9ab448e77e85a9c965a7c02f2c50/src/java.base/share/classes/sun/net/www/protocol/http/Authentica

Re: RFR: 8287318: ConcurrentModificationException in sun.net.httpserver.ServerImpl$Dispatcher [v2]

2022-05-31 Thread Daniel Fuchs
On Tue, 31 May 2022 15:11:03 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which addresses the issue noted in >> https://bugs.openjdk.java.net/browse/JDK-8287318? >> >> The `ServerImpl` has a `Dispatcher` thread which uses a `Selector` to select >> keys of interested. Th

Re: RFR: 8287318: ConcurrentModificationException in sun.net.httpserver.ServerImpl$Dispatcher

2022-05-31 Thread Daniel Fuchs
On Thu, 26 May 2022 07:17:12 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which addresses the issue noted in > https://bugs.openjdk.java.net/browse/JDK-8287318? > > The `ServerImpl` has a `Dispatcher` thread which uses a `Selector` to select > keys of interested. The sel

Re: RFR: 8287104: AddressChangeListener thread inherits CCL and can cause memory leak for webapp-servers [v3]

2022-05-25 Thread Daniel Fuchs
On Wed, 25 May 2022 09:30:46 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which addresses >> https://bugs.openjdk.java.net/browse/JDK-8287104? >> >> The change in this commit now uses an `InnocuousThread` to create a thread >> with `null` context classloader. The `Runna

Re: RFR: 8287104: AddressChangeListener thread inherits CCL and can cause memory leak for webapp-servers [v2]

2022-05-24 Thread Daniel Fuchs
On Mon, 23 May 2022 12:31:40 GMT, Jaikiran Pai wrote: >> Can I please get a review of this change which addresses >> https://bugs.openjdk.java.net/browse/JDK-8287104? >> >> The change in this commit now uses an `InnocuousThread` to create a thread >> with `null` context classloader. The `Runna

Re: RFR: 8286873: Improve websocket test execution time

2022-05-17 Thread Daniel Fuchs
On Tue, 17 May 2022 12:45:52 GMT, Daniel Jeliński wrote: > This PR improves the execution time of jdk_net tests (and, by extension, > tier2) by about 3 minutes. > > Tests located under `jdk/java/net/httpclient/websocket` are never run in > parallel. Each of the 8 modified `Pending***` tests or

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v8]

2022-05-16 Thread Daniel Fuchs
On Mon, 16 May 2022 08:59:43 GMT, Conor Cleary wrote: >> **Issue** >> When using the `HttpClient.send()` to send a GET request created using the >> `HttpRequest.newBuilder()`, a `Content-length: 0` header is set. This >> behaviour causes issues with many services as a body related header is >>

Re: RFR: 8209137: Add ability to bind to specific local address to HTTP client [v20]

2022-05-16 Thread Daniel Fuchs
On Sun, 15 May 2022 06:43:27 GMT, Jaikiran Pai wrote: >> This change proposes to implement the enhancement noted in >> https://bugs.openjdk.java.net/browse/JDK-8209137. >> >> The change introduces a new API to allow applications to build a >> `java.net.http.HTTPClient` configured with a specif

Integrated: 8286194: ExecutorShutdown test fails intermittently

2022-05-13 Thread Daniel Fuchs
On Thu, 5 May 2022 19:03:13 GMT, Daniel Fuchs wrote: > Hi, please find here a patch that solves a rare intermittent test failure > observed in the test `java/net/httpclient/ExecutorShutdown.java` > > A race condition coupled with some too eager synchronization was causing a > d

Re: RFR: 8286194: ExecutorShutdown test fails intermittently [v3]

2022-05-13 Thread Daniel Fuchs
On Fri, 13 May 2022 11:09:31 GMT, Michael McMahon wrote: > Question about the code copied in from ThreadInfo. Is there any way we could > request a change to that class to adjust the number of stack frames printed? Thanks Michael. I have logged https://bugs.openjdk.java.net/browse/JDK-8286720

Integrated: 8286386: Address possibly lossy conversions in java.net.http

2022-05-12 Thread Daniel Fuchs
On Wed, 11 May 2022 15:42:25 GMT, Daniel Fuchs wrote: > In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http This pull request has now been integrated. Changeset:

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v7]

2022-05-12 Thread Daniel Fuchs
On Fri, 6 May 2022 13:46:41 GMT, Conor Cleary wrote: >> **Issue** >> When using the `HttpClient.send()` to send a GET request created using the >> `HttpRequest.newBuilder()`, a `Content-length: 0` header is set. This >> behaviour causes issues with many services as a body related header is >>

Re: RFR: 8284585: PushPromiseContinuation test fails intermittently in timeout [v3]

2022-05-12 Thread Daniel Fuchs
On Thu, 12 May 2022 11:54:55 GMT, Conor Cleary wrote: >> **Issue** >> A recent fix for >> [JDK-8263031](https://bugs.openjdk.java.net/browse/JDK-8263031), which >> addressed the httpclient being unable to properly process Http/2 PushPromise >> frames followed by continuations caused intermitte

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v9]

2022-05-12 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v8]

2022-05-12 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Mo

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v7]

2022-05-12 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision:

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v7]

2022-05-12 Thread Daniel Fuchs
On Thu, 12 May 2022 11:41:04 GMT, Pavel Rappo wrote: >> OK - I will change codeLengthOf as suggested. It was not immediately >> obvious to me that the values would fit in the first 31 bits. > >> OK - I will change codeLengthOf as suggested. It was not immediately obvious >> to me that the valu

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v6]

2022-05-12 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: len

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v5]

2022-05-12 Thread Daniel Fuchs
On Thu, 12 May 2022 09:15:19 GMT, Pavel Rappo wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Revert adding char constants > > src/java.net.http/share/classes/jdk/internal/net/http/we

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v5]

2022-05-12 Thread Daniel Fuchs
On Thu, 12 May 2022 09:00:37 GMT, Pavel Rappo wrote: >> This is what I mean: >> >> jshell> long codeLengthOf = (long)Integer.MAX_VALUE + 1 >> codeLengthOf ==> 2147483648 >> >> jshell> int bufferLen = 0 >> bufferLen ==> 0 >> >> jshell> bufferLen + codeLengthOf <= 64 >> $3 ==> false >> >> jshel

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v5]

2022-05-12 Thread Daniel Fuchs
On Thu, 12 May 2022 08:42:39 GMT, Daniel Fuchs wrote: >> codeLengthOf() returns long. It could be changed to return int with a cast >> internally and then you could avoid the two new casts. > > No because the int returned could be negative, while the long will not. > As

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v5]

2022-05-12 Thread Daniel Fuchs
On Wed, 11 May 2022 20:31:00 GMT, Michael McMahon wrote: >> I believe the method returns an "unsigned int" - having the method return an >> int would then potentially cause `bufferLen + len <= 64` to yield true when >> it shouldn't. Hopefully @pavelrappo will comment. > > codeLengthOf() returns

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v5]

2022-05-11 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Reve

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v4]

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 18:25:00 GMT, Daniel Fuchs wrote: >> @RogerRiggs Actually - I'm no longer sure that this will work: >> >> >> jshell> char x = 0b1000_ >> x ==> '耀' >> >> jshell> var y = ~x >> y ==&

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v4]

2022-05-11 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Reve

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v3]

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 18:23:30 GMT, Daniel Fuchs wrote: >> 👍 I'd put `_MASK` in the name along with whatever name is used for the bits >> in the frame spec . > > @RogerRiggs Actually - I'm no longer sure that this will work: > > > jshell> char x = 0b1

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v3]

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 17:49:28 GMT, Roger Riggs wrote: >> Ah! Good point. Maybe I should use a constant and get rid of the cast. > > 👍 I'd put `_MASK` in the name along with whatever name is used for the bits > in the frame spec . @RogerRiggs Actually - I'm no longer sure that this will work: j

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v3]

2022-05-11 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision:

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v2]

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 17:49:28 GMT, Roger Riggs wrote: >> Ah! Good point. Maybe I should use a constant and get rid of the cast. > > 👍 I'd put `_MASK` in the name along with whatever name is used for the bits > in the frame spec . Done - PR: https://git.openjdk.java.net/jdk/pull/865

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http [v2]

2022-05-11 Thread Daniel Fuchs
> In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision:

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 17:37:44 GMT, Roger Riggs wrote: >> Yes - that's my understanding. > > These methods either set or clear a single bit in `firstChar`. > The constant is an `int` so its complement is a 32 bit int. > > It could also be written as `~ (char) 0b100_000`. Then the 16 bit

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 16:52:07 GMT, Michael McMahon wrote: >> In relation to >> [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find >> here a patch that addresses possibly lossy conversions in java.net.http > > src/java.net.http/share/classes/jdk/internal/net/http/hpack/Q

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 16:55:16 GMT, Michael McMahon wrote: >> In relation to >> [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find >> here a patch that addresses possibly lossy conversions in java.net.http > > src/java.net.http/share/classes/jdk/internal/net/http/websock

Re: RFR: 8286386: Address possibly lossy conversions in java.net.http

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 15:42:25 GMT, Daniel Fuchs wrote: > In relation to > [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find > here a patch that addresses possibly lossy conversions in java.net.http @pavelrappo I would appreciate if you could review thes

RFR: 8286386: Address possibly lossy conversions in java.net.http

2022-05-11 Thread Daniel Fuchs
In relation to [JDK-8244681](https://bugs.openjdk.java.net/browse/JDK-8244681), please find here a patch that addresses possibly lossy conversions in java.net.http - Commit messages: - Fix comments - 8286386: Address possibly lossy conversions in java.net.http Changes: https://gi

Re: RFR: 8209137: Add ability to bind to specific local address to HTTP client [v19]

2022-05-11 Thread Daniel Fuchs
On Wed, 11 May 2022 11:34:33 GMT, Michael McMahon wrote: >> Hello Michael, >> Most users will be using the `HttpClient.newBuilder()` to create the >> builder, so this note about `UnsupportedOperationException` can be >> confusing. However, for implementations (libraries?) which provide their

Re: RFR: 8209137: Add ability to bind to specific local address to HTTP client [v19]

2022-05-10 Thread Daniel Fuchs
On Tue, 10 May 2022 13:51:37 GMT, Jaikiran Pai wrote: >> This change proposes to implement the enhancement noted in >> https://bugs.openjdk.java.net/browse/JDK-8209137. >> >> The change introduces a new API to allow applications to build a >> `java.net.http.HTTPClient` configured with a specif

Re: RFR: 8209137: Add ability to bind to specific local address to HTTP client [v18]

2022-05-10 Thread Daniel Fuchs
On Tue, 10 May 2022 13:36:18 GMT, Daniel Fuchs wrote: >> Jaikiran Pai has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Daniel's review suggestion - add a test to verify the behaviour of the >

Re: RFR: 8209137: Add ability to bind to specific local address to HTTP client [v18]

2022-05-10 Thread Daniel Fuchs
On Tue, 10 May 2022 12:37:47 GMT, Jaikiran Pai wrote: >> This change proposes to implement the enhancement noted in >> https://bugs.openjdk.java.net/browse/JDK-8209137. >> >> The change introduces a new API to allow applications to build a >> `java.net.http.HTTPClient` configured with a specif

Re: RFR: 8209137: Add ability to bind to specific local address to HTTP client [v17]

2022-05-09 Thread Daniel Fuchs
On Mon, 9 May 2022 07:52:29 GMT, Jaikiran Pai wrote: >> This change proposes to implement the enhancement noted in >> https://bugs.openjdk.java.net/browse/JDK-8209137. >> >> The change introduces a new API to allow applications to build a >> `java.net.http.HTTPClient` configured with a specifi

Integrated: 8286293: Tests ShortResponseBody and ShortResponseBodyWithRetry should use less resources

2022-05-09 Thread Daniel Fuchs
On Fri, 6 May 2022 11:04:29 GMT, Daniel Fuchs wrote: > Hi, > > Please find here a simple test fix that re-architecture ShortResponseBody for > better resource usage. > The test is split to test GET and POST separately and avoids testing GET > twice. This pull request has n

Re: RFR: 8286293: Tests ShortResponseBody and ShortResponseBodyWithRetry should use less resources [v2]

2022-05-09 Thread Daniel Fuchs
On Mon, 9 May 2022 11:57:30 GMT, Michael McMahon wrote: >> Daniel Fuchs 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 conta

Re: RFR: 8286293: Tests ShortResponseBody and ShortResponseBodyWithRetry should use less resources [v3]

2022-05-09 Thread Daniel Fuchs
> Hi, > > Please find here a simple test fix that re-architecture ShortResponseBody for > better resource usage. > The test is split to test GET and POST separately and avoids testing GET > twice. Daniel Fuchs has updated the pull request incrementally with one additional

Re: RFR: 8286293: Tests ShortResponseBody and ShortResponseBodyWithRetry should use less resources [v2]

2022-05-07 Thread Daniel Fuchs
> Hi, > > Please find here a simple test fix that re-architecture ShortResponseBody for > better resource usage. > The test is split to test GET and POST separately and avoids testing GET > twice. Daniel Fuchs has updated the pull request with a new target base due to a merge

Re: RFR: 8286194: ExecutorShutdown test fails intermittently [v3]

2022-05-07 Thread Daniel Fuchs
he test (remove the limit that limited the stack traces > to 8 element max by no longer relying on `ThreadInfo::toString`) Daniel Fuchs 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 merg

Re: RFR: JDK-8280498: jdk/java/net/Inet4Address/PingThis.java fails on AIX [v7]

2022-05-06 Thread Daniel Fuchs
On Thu, 5 May 2022 12:55:57 GMT, Michael Felt wrote: >> with IP "0.0.0.0" >> >> - it either does nothing and ping fails, or, in some virtual environments >> is treated as the default route address. >> - IPv6 support for ::1 is available since 1977; however, ::0 is not accepted >> as a vaild psue

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v6]

2022-05-06 Thread Daniel Fuchs
On Fri, 6 May 2022 10:39:38 GMT, Daniel Fuchs wrote: >> Conor Cleary has updated the pull request incrementally with one additional >> commit since the last revision: >> >> 8283544: Improved logging, drain input stream > > src/java.net.http/share

RFR: 8286293: Tests ShortResponseBody and ShortResponseBodyWithRetry should use less resources

2022-05-06 Thread Daniel Fuchs
Hi, Please find here a simple test fix that re-architecture ShortResponseBody for better resource usage. The test is split to test GET and POST separately and avoids testing GET twice. - Commit messages: - 8286293: Tests ShortResponseBody and ShortResponseBodyWithRetry should use

Re: RFR: 8284585: PushPromiseContinuation test fails intermittently in timeout [v2]

2022-05-06 Thread Daniel Fuchs
On Thu, 5 May 2022 13:37:08 GMT, Conor Cleary wrote: >> **Issue** >> A recent fix for >> [JDK-8263031](https://bugs.openjdk.java.net/browse/JDK-8263031), which >> addressed the httpclient being unable to properly process Http/2 PushPromise >> frames followed by continuations caused intermitten

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v6]

2022-05-06 Thread Daniel Fuchs
On Fri, 6 May 2022 10:33:31 GMT, Conor Cleary wrote: >> **Issue** >> When using the `HttpClient.send()` to send a GET request created using the >> `HttpRequest.newBuilder()`, a `Content-length: 0` header is set. This >> behaviour causes issues with many services as a body related header is >>

Re: RFR: 8286194: ExecutorShutdown test fails intermittently [v2]

2022-05-06 Thread Daniel Fuchs
On Fri, 6 May 2022 05:16:15 GMT, Jaikiran Pai wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Added a comment to ReferenceTracker.java as suggested in the review > > src/java.net.h

Re: RFR: 8286194: ExecutorShutdown test fails intermittently [v2]

2022-05-06 Thread Daniel Fuchs
he test (remove the limit that limited the stack traces > to 8 element max by no longer relying on `ThreadInfo::toString`) Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Added a comment to ReferenceTracker.java

Re: RFR: 8286194: ExecutorShutdown test fails intermittently

2022-05-06 Thread Daniel Fuchs
On Fri, 6 May 2022 04:57:00 GMT, Jaikiran Pai wrote: >> Hi, please find here a patch that solves a rare intermittent test failure >> observed in the test `java/net/httpclient/ExecutorShutdown.java` >> >> A race condition coupled with some too eager synchronization was causing a >> deadlock bet

Re: RFR: 8286194: ExecutorShutdown test fails intermittently

2022-05-06 Thread Daniel Fuchs
On Fri, 6 May 2022 04:49:53 GMT, Jaikiran Pai wrote: >> Hi, please find here a patch that solves a rare intermittent test failure >> observed in the test `java/net/httpclient/ExecutorShutdown.java` >> >> A race condition coupled with some too eager synchronization was causing a >> deadlock bet

RFR: 8286194: ExecutorShutdown test fails intermittently

2022-05-05 Thread Daniel Fuchs
Hi, please find here a patch that solves a rare intermittent test failure observed in the test `java/net/httpclient/ExecutorShutdown.java` A race condition coupled with some too eager synchronization was causing a deadlock between an Http2Connection close, a thread trying to shutdown the HttpCl

Re: RFR: 8284585: PushPromiseContinuation test fails intermittently in timeout

2022-05-04 Thread Daniel Fuchs
On Tue, 3 May 2022 15:00:51 GMT, Conor Cleary wrote: > **Issue** > A recent fix for > [JDK-8263031](https://bugs.openjdk.java.net/browse/JDK-8263031), which > addressed the httpclient being unable to properly process Http/2 PushPromise > frames followed by continuations caused intermittent fai

Re: RFR: 8284585: PushPromiseContinuation test fails intermittently in timeout

2022-05-04 Thread Daniel Fuchs
On Tue, 3 May 2022 15:00:51 GMT, Conor Cleary wrote: > **Issue** > A recent fix for > [JDK-8263031](https://bugs.openjdk.java.net/browse/JDK-8263031), which > addressed the httpclient being unable to properly process Http/2 PushPromise > frames followed by continuations caused intermittent fai

Re: RFR: JDK-8280498: jdk/java/net/Inet4Address/PingThis.java fails on AIX [v4]

2022-04-29 Thread Daniel Fuchs
On Fri, 29 Apr 2022 15:06:28 GMT, Jaikiran Pai wrote: >> too much Python (no semi-colons) - great catch. >> >> Looking into how to verify proposed changes using jenkins (adoptium). When >> not in aqa-tests, more difficult (for me) too get it tested. (aka Better >> next time). > > @aixtools, if

Re: RFR: JDK-8280498: jdk/java/net/Inet4Address/PingThis.java fails on AIX [v4]

2022-04-29 Thread Daniel Fuchs
On Fri, 29 Apr 2022 12:11:27 GMT, Michael Felt wrote: >> Good catch! > > too much Python (no semi-colons) - great catch. > > Looking into how to verify proposed changes using jenkins (adoptium). When > not in aqa-tests, more difficult (for me) too get it tested. (aka Better next > time). Stil

Re: RFR: JDK-8280498: jdk/java/net/Inet4Address/PingThis.java fails on AIX [v4]

2022-04-28 Thread Daniel Fuchs
On Thu, 28 Apr 2022 14:56:25 GMT, Michael McMahon wrote: >> Michael Felt has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Adjusted and moved comments per review > > test/jdk/java/net/Inet4Address/PingThis.java line 49: > >> 47: publi

Re: RFR: 8285671: java/nio/channels/etc/PrintSupportedOptions.java and java/nio/channels/DatagramChannel/AfterDisconnect.java are failing [v2]

2022-04-27 Thread Daniel Fuchs
On Wed, 27 Apr 2022 14:27:01 GMT, Michael McMahon wrote: >> src/jdk.net/macosx/native/libextnet/MacOSXSocketOptions.c line 209: >> >>> 207: return JNI_FALSE; >>> 208: } >>> 209: fd = socket(AF_INET6, SOCK_DGRAM, 0); >> >> So if IPv6 is not supported on the machine, won't that re

Re: RFR: 8285671: java/nio/channels/etc/PrintSupportedOptions.java and java/nio/channels/DatagramChannel/AfterDisconnect.java are failing [v3]

2022-04-27 Thread Daniel Fuchs
On Wed, 27 Apr 2022 14:57:34 GMT, Michael McMahon wrote: >> Hi, >> >> Can I get the following fix reviewed please? JDK-8284890 was pushed >> yesterday and is causing failures on older versions of macOS that do not >> support the option. The fix here is to check at initialization time whether

Re: RFR: JDK-8280498: jdk/java/net/Inet4Address/PingThis.java fails on AIX [v4]

2022-04-27 Thread Daniel Fuchs
On Wed, 27 Apr 2022 15:27:45 GMT, Michael Felt wrote: >> with IP "0.0.0.0" >> >> - it either does nothing and ping fails, or, in some virtual environments >> is treated as the default route address. >> - IPv6 support for ::1 is available since 1977; however, ::0 is not accepted >> as a vaild psu

Re: RFR: 8285671: java/nio/channels/etc/PrintSupportedOptions.java and java/nio/channels/DatagramChannel/AfterDisconnect.java are failing [v2]

2022-04-27 Thread Daniel Fuchs
On Wed, 27 Apr 2022 12:10:13 GMT, Michael McMahon wrote: >> Hi, >> >> Can I get the following fix reviewed please? JDK-8284890 was pushed >> yesterday and is causing failures on older versions of macOS that do not >> support the option. The fix here is to check at initialization time whether

Re: RFR: 8285671: java/nio/channels/etc/PrintSupportedOptions.java and java/nio/channels/DatagramChannel/AfterDisconnect.java are failing

2022-04-27 Thread Daniel Fuchs
On Wed, 27 Apr 2022 09:43:52 GMT, Michael McMahon wrote: > Hi, > > Can I get the following fix reviewed please? JDK-8284890 was pushed yesterday > and is causing failures on older versions of macOS that do not support the > option. The fix here is to check at initialization time whether it is

Re: RFR: 8285521: Minor improvements in java.net.URI

2022-04-26 Thread Daniel Fuchs
On Tue, 26 Apr 2022 12:41:38 GMT, Сергей Цыпанов wrote: > Btw, I see that `java.net.URI` duplicates some methods from > `sun.net.www.ParseUtil`. Should we consolidate them e.g. in a way of reusing > functionality of `sun.net.www.ParseUtil` in `java.net.URI`? I don't think the ratio benefit/ris

Re: RFR: 8285521: Minor improvements in java.net.URI

2022-04-26 Thread Daniel Fuchs
On Tue, 26 Apr 2022 12:39:50 GMT, Сергей Цыпанов wrote: >> src/java.base/share/classes/java/net/URI.java line 1921: >> >>> 1919: return sn - tn; >>> 1920: int val = 0; >>> 1921: int n = Math.min(sn, tn); >> >> Can we drop this change? I wouldn

Re: RFR: 8285521: Minor improvements in java.net.URI

2022-04-26 Thread Daniel Fuchs
On Tue, 26 Apr 2022 07:02:55 GMT, Сергей Цыпанов wrote: > - use `String.equalsIgnoreCase()` instead of hand-written code relying on > `String.charAt()` > - use `String.compareToIgnoreCase()` instead of hand-written code relying on > `String.charAt()` > - drop branches that are never executed >

Re: RFR: 8285366: Fix typos in serviceability

2022-04-21 Thread Daniel Fuchs
On Thu, 21 Apr 2022 14:03:39 GMT, Daniel Fuchs wrote: >> I ran `codespell` on modules owned by the serviceability team >> (`java.instrument java.management.rmi java.management jdk.attach >> jdk.hotspot.agent jdk.internal.jvmstat jdk.jcmd jdk.jconsole jdk.jdi >> j

Re: RFR: 8285366: Fix typos in serviceability

2022-04-21 Thread Daniel Fuchs
On Thu, 21 Apr 2022 11:22:48 GMT, Magnus Ihse Bursie wrote: > I ran `codespell` on modules owned by the serviceability team > (`java.instrument java.management.rmi java.management jdk.attach > jdk.hotspot.agent jdk.internal.jvmstat jdk.jcmd jdk.jconsole jdk.jdi > jdk.jdwp.agent jdk.jstatd jdk.

Re: RFR: 8284890: Support for Do not fragment IP socket options [v8]

2022-04-20 Thread Daniel Fuchs
On Wed, 20 Apr 2022 14:30:21 GMT, Michael McMahon wrote: >> Hi, >> >> Could I get the following PR review please? It adds a new JDK specific >> extended socket option >> called IP_DONTFRAGMENT, which disables IP packet fragmentation in both IPv4 >> and IPv6 >> UDP sockets (NIO DatagramChannels

Integrated: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task

2022-04-20 Thread Daniel Fuchs
On Mon, 24 Jan 2022 14:25:09 GMT, Daniel Fuchs wrote: > These changes make sure that pending requests are terminated if the selector > manager thread exits due to exceptions. > This includes: >1. completing CompletableFutures that were returned to the caller code >2. canc

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v9]

2022-04-20 Thread Daniel Fuchs
On Sat, 16 Apr 2022 11:06:21 GMT, Daniel Fuchs wrote: >> These changes make sure that pending requests are terminated if the selector >> manager thread exits due to exceptions. >> This includes: >>1. completing CompletableFutures that were returned to the caller

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v5]

2022-04-19 Thread Daniel Fuchs
On Fri, 8 Apr 2022 10:19:08 GMT, Jaikiran Pai wrote: >> Hello Conor, >> >> I had a look at this latest update to the `Http1Request`. The github diff >> isn't easy to understand/explain in this case, so I'll paste here the latest >> code contained in this PR, from that method. It looks like: >

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v5]

2022-04-19 Thread Daniel Fuchs
On Tue, 19 Apr 2022 16:44:35 GMT, Daniel Fuchs wrote: >> test/jdk/java/net/httpclient/ContentLengthHeaderTest.java line 202: >> >>> 200: } else { >>> 201: String responseBody = exchange.getRequestMethod() + " >>>

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v5]

2022-04-19 Thread Daniel Fuchs
On Thu, 7 Apr 2022 13:53:35 GMT, Conor Cleary wrote: >> **Issue** >> When using the `HttpClient.send()` to send a GET request created using the >> `HttpRequest.newBuilder()`, a `Content-length: 0` header is set. This >> behaviour causes issues with many services as a body related header is >>

Re: RFR: 8283544: HttpClient GET method adds Content-Length: 0 header [v5]

2022-04-19 Thread Daniel Fuchs
On Tue, 19 Apr 2022 16:43:12 GMT, Daniel Fuchs wrote: >> Conor Cleary has updated the pull request incrementally with one additional >> commit since the last revision: >> >> 8283544: Updated URI creation > > test/jdk/java/net/httpclient/ContentLengthHeade

Re: RFR: 8284890: Support for Do not fragment IP socket options [v5]

2022-04-19 Thread Daniel Fuchs
On Tue, 19 Apr 2022 15:54:02 GMT, Michael McMahon wrote: >> test/jdk/jdk/net/ExtendedSocketOption/DontFragmentTest.java line 44: >> >>> 42: StandardProtocolFamily fam = args[0].equals("ipv4") ? INET : >>> INET6; >>> 43: System.out.println("Family = " + fam); >>> 44: test

Re: RFR: 8284890: Support for Do not fragment IP socket options [v5]

2022-04-19 Thread Daniel Fuchs
On Tue, 19 Apr 2022 14:47:01 GMT, Michael McMahon wrote: >> Hi, >> >> Could I get the following PR review please? It adds a new JDK specific >> extended socket option >> called IP_DONTFRAGMENT, which disables IP packet fragmentation in both IPv4 >> and IPv6 >> UDP sockets (NIO DatagramChannels

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v9]

2022-04-16 Thread Daniel Fuchs
se is > read. Completing a completable future that is already completed has no > effect, this case is handled by completing the BodySubscriber too. Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Fixed accepted exception logging in tests

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v8]

2022-04-16 Thread Daniel Fuchs
se is > read. Completing a completable future that is already completed has no > effect, this case is handled by completing the BodySubscriber too. Daniel Fuchs has updated the pull request incrementally with two additional commits since the last revision: - File forgotten in previous commit -

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v7]

2022-04-15 Thread Daniel Fuchs
se is > read. Completing a completable future that is already completed has no > effect, this case is handled by completing the BodySubscriber too. Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Improve diagnostics f

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v6]

2022-04-15 Thread Daniel Fuchs
On Fri, 15 Apr 2022 14:35:33 GMT, Daniel Fuchs wrote: >> These changes make sure that pending requests are terminated if the selector >> manager thread exits due to exceptions. >> This includes: >>1. completing CompletableFutures that were returned to the caller

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v6]

2022-04-15 Thread Daniel Fuchs
se is > read. Completing a completable future that is already completed has no > effect, this case is handled by completing the BodySubscriber too. Daniel Fuchs has updated the pull request incrementally with two additional commits since the last revision: - Fixed exception handling in te

Re: RFR: 8284890: Support for Do not fragment IP socket options

2022-04-15 Thread Daniel Fuchs
On Thu, 14 Apr 2022 16:04:22 GMT, Michael McMahon wrote: > Hi, > > Could I get the following PR review please? It adds a new JDK specific > extended socket option > called IP_DONTFRAGMENT, which disables IP packet fragmentation in both IPv4 > and IPv6 > UDP sockets (NIO DatagramChannels). For

Integrated: 8284892: java/net/httpclient/http2/TLSConnection.java fails intermittently

2022-04-15 Thread Daniel Fuchs
On Thu, 14 Apr 2022 18:26:00 GMT, Daniel Fuchs wrote: > java/net/httpclient/http2/TLSConnection.java has been observed failing (even > though rarely) in test jobs. > > The issue is that the handler used on the the server sides maintains a > volatile `sslSession` field whi

Re: RFR: 8277969: HttpClient SelectorManager shuts down when custom Executor rejects a task [v5]

2022-04-15 Thread Daniel Fuchs
se is > read. Completing a completable future that is already completed has no > effect, this case is handled by completing the BodySubscriber too. Daniel Fuchs has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains eight commits: - Me

Re: RFR: 8284892: java/net/httpclient/http2/TLSConnection.java fails intermittently [v2]

2022-04-14 Thread Daniel Fuchs
can observe the previous value, > which was set by the previous request. Checking of SSL parameters on the > client side then usually fails, as it is looking at the wrong session. > > The proposed fix is very simple: just update the `sslSession` field a little > earlier - before wr

  1   2   3   4   5   6   7   8   9   10   >