Re: RFR: 8262027: Improve how HttpConnection detects a closed channel when taking/returning a connection to the pool [v4]

2021-02-19 Thread Daniel Fuchs
was on windows, where > apparently closing the socket on the server side can cause a reset, even when > SO_LINGER and TCP_NODELAY are specified. I solved that by adding a small > delay between socket.shutdownOutput() and socket.close() in the test proxy - > when running on windows.

Re: RFR: 8262027: Improve how HttpConnection detects a closed channel when taking/returning a connection to the pool [v5]

2021-02-22 Thread Daniel Fuchs
was on windows, where > apparently closing the socket on the server side can cause a reset, even when > SO_LINGER and TCP_NODELAY are specified. I solved that by adding a small > delay between socket.shutdownOutput() and socket.close() in the test proxy - > when running on windo

Re: RFR: 8262027: Improve how HttpConnection detects a closed channel when taking/returning a connection to the pool [v2]

2021-02-22 Thread Daniel Fuchs
On Fri, 19 Feb 2021 19:34:26 GMT, Michael McMahon wrote: >> There's no guarantee that the proxy will have read all the bytes sent by the >> client - even if it attempts to drain the connection. So the only sane >> reaction if you're not going to parse the request body is to close the >> connec

Re: RFR: 8224775: test/jdk/com/sun/jdi/JdwpListenTest.java failed to attach

2021-02-22 Thread Daniel Fuchs
On Thu, 18 Feb 2021 21:43:00 GMT, Alex Menkov wrote: > The fix also partially fixes JdwpAttachTest failures (JDK-8253940). > The failures are caused by network configuration changes during test > execution ("global" IPv6 addresses disappears from interface). > To minimize chances of intermittent

Re: RFR: 8224775: test/jdk/com/sun/jdi/JdwpListenTest.java failed to attach [v2]

2021-02-23 Thread Daniel Fuchs
On Mon, 22 Feb 2021 21:36:52 GMT, Alex Menkov wrote: >> The fix also partially fixes JdwpAttachTest failures (JDK-8253940). >> The failures are caused by network configuration changes during test >> execution ("global" IPv6 addresses disappears from interface). >> To minimize chances of intermit

Re: RFR: 8262027: Improve how HttpConnection detects a closed channel when taking/returning a connection to the pool [v6]

2021-02-23 Thread Daniel Fuchs
was on windows, where > apparently closing the socket on the server side can cause a reset, even when > SO_LINGER and TCP_NODELAY are specified. I solved that by adding a small > delay between socket.shutdownOutput() and socket.close() in the test proxy - > when running on windo

Re: RFR: 8262027: Improve how HttpConnection detects a closed channel when taking/returning a connection to the pool [v5]

2021-02-23 Thread Daniel Fuchs
On Tue, 23 Feb 2021 14:06:41 GMT, Chris Hegarty 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

Integrated: 8262027: Improve how HttpConnection detects a closed channel when taking/returning a connection to the pool

2021-02-24 Thread Daniel Fuchs
On Fri, 19 Feb 2021 16:08:25 GMT, Daniel Fuchs wrote: > Hi, > > Please find here a fix for: > 8262027: Improve how HttpConnection detects a closed channel when > taking/returning a connection to the pool > > While writing a new test to verify that it was possible

Re: RFR: 8260366: ExtendedSocketOptions can deadlock in some circumstances [v5]

2021-02-24 Thread Daniel Fuchs
On Fri, 19 Feb 2021 04:29:55 GMT, Jaikiran Pai wrote: >> Can I please get a review for this change which proposes to fix the issue >> reported in https://bugs.openjdk.java.net/browse/JDK-8260366? >> >> The issue relates to the concurrent classloading of >> `sun.net.ext.ExtendedSocketOptions` a

Re: RFR: 8262296 Fix remaining doclint warnings in jdk.httpserver

2021-02-24 Thread Daniel Fuchs
On Wed, 24 Feb 2021 13:58:38 GMT, Chris Hegarty wrote: > Trivial clean up of remaining doclint warnings in jdk.httpserver. > > The minor spec clarifications do not amount to a normative change, so no CSR > is required (they're documented the obvious and only possible behaviour). LGTM ---

Re: RFR: 8262296 Fix remaining doclint warnings in jdk.httpserver [v2]

2021-02-24 Thread Daniel Fuchs
On Wed, 24 Feb 2021 16:21:59 GMT, Chris Hegarty wrote: >> Trivial clean up of remaining doclint warnings in jdk.httpserver. >> >> The minor spec clarifications do not amount to a normative change, so no CSR >> is required (they're documented the obvious and only possible behaviour). > > Chris

RFR: 8253100: Fix "no comment" warnings in java.base/java.net

2021-02-24 Thread Daniel Fuchs
Hi, Please find here a change that fixes "no comment" warnings generated by `javadoc -Xdoclint` for `java.base/java.net` - Commit messages: - Fixed trailing whitespace - 8253100: Fix "no comment" warnings in java.base/java.net Changes: https://git.openjdk.java.net/jdk/pull/2715/

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v2]

2021-02-25 Thread Daniel Fuchs
On Thu, 25 Feb 2021 09:24:50 GMT, Patrick Concannon wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed comment > > src/java.base/share/classes/java/net/HttpRetryException.

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v2]

2021-02-25 Thread Daniel Fuchs
> Hi, > > Please find here a change that fixes "no comment" warnings generated by > `javadoc -Xdoclint` for `java.base/java.net` Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Fixed comment - C

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net

2021-02-25 Thread Daniel Fuchs
On Wed, 24 Feb 2021 20:42:52 GMT, Daniel Fuchs wrote: > Hi, > > Please find here a change that fixes "no comment" warnings generated by > `javadoc -Xdoclint` for `java.base/java.net` The CSR draft can be reviewed here: https://bugs.openjdk.java.net/browse/JDK-8262

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v2]

2021-02-25 Thread Daniel Fuchs
On Thu, 25 Feb 2021 16:59:07 GMT, Naoto Sato wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed comment > > src/java.base/share/classes/java/net/InetSocketAddress.java line

Re: RFR: 8262195: Harden tests that use the HostsFileNameService (jdk.net.hosts.file property) [v2]

2021-02-25 Thread Daniel Fuchs
On Thu, 25 Feb 2021 15:38:02 GMT, Conor Cleary wrote: >> A number of net tests use a >> **[HostsFileNameService](https://github.com/openjdk/jdk/blob/382e38dd246596ec94a1f1ce0e0f9e87f53366c7/src/java.base/share/classes/java/net/InetAddress.java#L955)** >> to verify either the functionality of th

Re: RFR: 8262195: Harden tests that use the HostsFileNameService (jdk.net.hosts.file property) [v2]

2021-02-25 Thread Daniel Fuchs
On Thu, 25 Feb 2021 19:16:58 GMT, Conor Cleary wrote: >> test/jdk/java/net/InetAddress/InternalNameServiceWithNoHostsFileTest.java >> line 32: >> >>> 30: * thrown >>> 31: * @run main/othervm -Djdk.net.hosts.file=TestHosts-II >>> -Dsun.net.inetaddr.ttl=0 >>> 32: * InternalN

Re: RFR: JDK-8262430: doclint warnings in java.base module

2021-02-26 Thread Daniel Fuchs
On Thu, 25 Feb 2021 22:59:23 GMT, Jonathan Gibbons wrote: > Please review some simple doc fixes in the `java.base` module. Two were > reported by doclint; the spelling error was detected by the IDE. LGTM - Marked as reviewed by dfuchs (Reviewer). PR: https://git.openjdk.java.net

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v3]

2021-02-26 Thread Daniel Fuchs
> Hi, > > Please find here a change that fixes "no comment" warnings generated by > `javadoc -Xdoclint` for `java.base/java.net` Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Fixed @throws to conform

Re: RFR: 8262195: Harden tests that use the HostsFileNameService (jdk.net.hosts.file property) [v2]

2021-02-26 Thread Daniel Fuchs
On Thu, 25 Feb 2021 15:38:02 GMT, Conor Cleary wrote: >> A number of net tests use a >> **[HostsFileNameService](https://github.com/openjdk/jdk/blob/382e38dd246596ec94a1f1ce0e0f9e87f53366c7/src/java.base/share/classes/java/net/InetAddress.java#L955)** >> to verify either the functionality of th

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v4]

2021-03-01 Thread Daniel Fuchs
> Hi, > > Please find here a change that fixes "no comment" warnings generated by > `javadoc -Xdoclint` for `java.base/java.net` 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

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v5]

2021-03-01 Thread Daniel Fuchs
> Hi, > > Please find here a change that fixes "no comment" warnings generated by > `javadoc -Xdoclint` for `java.base/java.net` Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Fixed trailing whitespaces

Re: RFR: 8253100: Fix "no comment" warnings in java.base/java.net [v3]

2021-03-01 Thread Daniel Fuchs
On Sat, 27 Feb 2021 10:04:28 GMT, Alan Bateman wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed @throws to conform to the style of other @throws in java.net.URI > > Looks fi

Re: RFR: 8252831: Correct "no comment" warnings in jdk.net module

2021-03-02 Thread Daniel Fuchs
On Tue, 2 Mar 2021 10:15:13 GMT, Patrick Concannon wrote: > Hi, > > Could someone please review my changeset that fixes the "no comment" warnings > generated by `javadoc -Xdoclint` for `java.base/jdk.net`? > > Kind regards, > Patrick LGTM - Marked as reviewed by dfuchs (Reviewe

Re: RFR: JDK-8260925: HttpsURLConnection does not work with other JSSE provider.

2021-03-02 Thread Daniel Fuchs
On Tue, 16 Feb 2021 07:50:05 GMT, Vyom Tewari wrote: > HttpsURLConnection, works with SunJSSE provider but does not work with other > JSSE provider. In case of SunJSSE , HttpsURLConnection set the host name as > follows > > s = (SSLSocket)serverSocket; >if (s instanceof SSLSocketImpl) { >

Integrated: 8253100: Fix "no comment" warnings in java.base/java.net

2021-03-02 Thread Daniel Fuchs
On Wed, 24 Feb 2021 20:42:52 GMT, Daniel Fuchs wrote: > Hi, > > Please find here a change that fixes "no comment" warnings generated by > `javadoc -Xdoclint` for `java.base/java.net` This pull request has now been integrated. Changeset: 5f4bc0ac Author:Daniel F

Re: RFR: JDK-8260925: HttpsURLConnection does not work with other JSSE provider.

2021-03-02 Thread Daniel Fuchs
On Tue, 2 Mar 2021 14:39:43 GMT, Vyom Tewari wrote: >> src/java.base/share/classes/sun/net/www/protocol/https/HttpsClient.java line >> 569: >> >>> 567: SSLParameters paramaters = s.getSSLParameters(); >>> 568: >>> paramaters.setEndpointIdentificationAlgo

Re: RFR: JDK-8260925: HttpsURLConnection does not work with other JSSE provider.

2021-03-02 Thread Daniel Fuchs
On Tue, 2 Mar 2021 15:34:56 GMT, Vyom Tewari wrote: >> Did you try to run the httpclient tests? They make use of the httpserver - >> so they can also serve to test it - somewhat. >> More generally - please run jdk_net/tier2 tests. > > i ran tests, it looks > clean(https://github.com/vyommani/jd

Re: RFR: JDK-8260925: HttpsURLConnection does not work with other JSSE provider.

2021-03-03 Thread Daniel Fuchs
On Wed, 3 Mar 2021 08:51:13 GMT, Vyom Tewari wrote: >>> > HttpsURLConnection, works with SunJSSE provider but does not work with >>> > other JSSE provider. In case of SunJSSE , HttpsURLConnection set the host >>> > name as follows >>> > s = (SSLSocket)serverSocket; >>> > if (s instanceof SSLSoc

Re: RFR: JDK-8260925: HttpsURLConnection does not work with other JSSE provider. [v2]

2021-03-03 Thread Daniel Fuchs
On Wed, 3 Mar 2021 04:27:15 GMT, Vyom Tewari wrote: >> HttpsURLConnection, works with SunJSSE provider but does not work with other >> JSSE provider. In case of SunJSSE , HttpsURLConnection set the host name as >> follows >> >> s = (SSLSocket)serverSocket; >>if (s instanceof SSLSocketImpl)

Re: RFR: 8262935: Add missing logging to sun.net.httpserver.ServerImpl

2021-03-03 Thread Daniel Fuchs
On Wed, 3 Mar 2021 10:55:12 GMT, Julia Boes wrote: > Small fix to add logging to catch blocks where it was previously missing. LGTM - Marked as reviewed by dfuchs (Reviewer). PR: https://git.openjdk.java.net/jdk/pull/2808

RFR: 8263080: Obsolete relationship in MulticastSocket API documentation.

2021-03-05 Thread Daniel Fuchs
Now that DatagramSocket has been updated by JDK-8237352 to support joining multicast group, this sentence in the API class level documentation of MulticastSocket is obsolete and should be removed: "A MulticastSocket is a (UDP) DatagramSocket, with additional capabilities for joining "groups" of

Re: RFR: 8263233: Update java.net and java.nio to use instanceof pattern variable

2021-03-09 Thread Daniel Fuchs
On Tue, 9 Mar 2021 11:07:07 GMT, Patrick Concannon wrote: > Hi, > > Could someone please review my code for updating the code in the `java.net` > and `java.nio` packages to make use of the `instanceof` pattern variable? > > Kind regards, > Patrick LGTM. - Marked as reviewed by

Re: RFR: JDK-8262992: Improve `@see` output

2021-03-09 Thread Daniel Fuchs
On Tue, 9 Mar 2021 15:04:35 GMT, Hannes Wallnöfer wrote: > This changes the output for `@see` tags to a `` structure. A different > CSS style is used if any of the `@see` tag labels are longer than 30 > characters or contain a comma. > > The layout for the default CSS style is similar to the

Re: RFR: 8263080: Obsolete relationship in MulticastSocket API documentation. [v2]

2021-03-09 Thread Daniel Fuchs
nal capabilities for > joining "groups" of other multicast hosts on the internet." > > Not sure whether this requires a CSR. I guess not? Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Improved first sent

Re: RFR: 8263233: Update java.net and java.nio to use instanceof pattern variable [v3]

2021-03-09 Thread Daniel Fuchs
On Tue, 9 Mar 2021 20:07:14 GMT, Mark Sheppard wrote: >> Patrick Concannon has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8263233: Refactored equals method further > > src/java.base/share/classes/java/net/NetMulticastSocket.java line 21

Re: RFR: 8263233: Update java.net and java.nio to use instanceof pattern variable [v3]

2021-03-09 Thread Daniel Fuchs
On Tue, 9 Mar 2021 19:56:25 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review my code for updating the code in the `java.net` >> and `java.nio` packages to make use of the `instanceof` pattern variable? >> >> Kind regards, >> Patrick > > Patrick Concannon has updated the

Re: RFR: 8263080: Obsolete relationship in MulticastSocket API documentation. [v2]

2021-03-10 Thread Daniel Fuchs
On Wed, 10 Mar 2021 09:52:10 GMT, Patrick Concannon wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Improved first sentence > > src/java.base/share/classes/java/net/MulticastSocket.j

Re: RFR: 8263080: Obsolete relationship in MulticastSocket API documentation. [v3]

2021-03-10 Thread Daniel Fuchs
nal capabilities for > joining "groups" of other multicast hosts on the internet." > > Not sure whether this requires a CSR. I guess not? 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

Re: RFR: 8263442: Potential bug in jdk.internal.net.http.common.Utils.CONTEXT_RESTRICTED

2021-03-15 Thread Daniel Fuchs
On Fri, 12 Mar 2021 21:04:59 GMT, Michael McMahon wrote: > Hi, > > The fix for the reported bug in Utils.CONTEXT_RESTRICTED caused a couple of > regression failures, which turned out to be another bug exposed by this fix > where HTTP/1.1 CONNECT requests with authentication were filtering out

Re: RFR: 8263560: Remove needless wrapping with BufferedInputStream [v5]

2021-03-15 Thread Daniel Fuchs
On Mon, 15 Mar 2021 12:19:19 GMT, Сергей Цыпанов wrote: >> In some cases wrapping of `InputStream` with `BufferedInputStream` is >> redundant, e.g. in case the wrapped one is `ByteArrayOutputStream` which >> does not require any buffer having one within. >> >> Other cases are related to readi

Re: RFR: 8263560: Remove needless wrapping with BufferedInputStream [v6]

2021-03-15 Thread Daniel Fuchs
On Mon, 15 Mar 2021 18:01:20 GMT, Сергей Цыпанов wrote: >> In some cases wrapping of `InputStream` with `BufferedInputStream` is >> redundant, e.g. in case the wrapped one is `ByteArrayOutputStream` which >> does not require any buffer having one within. >> >> Other cases are related to readi

Re: RFR: 8187450: JNI local refs exceeds capacity warning in NetworkInterface::getAll [v4]

2021-03-16 Thread Daniel Fuchs
On Tue, 16 Mar 2021 14:12:46 GMT, Jonathan Dowland wrote: >> This is an adaptation of a patch originally written by Shafi Ahmad in >> a comment on the JBS page but never submitted or merged. >> >> With -Xcheck:jni, the method java.net.NetworkInterface.getAll very >> quickly breaches the default

Re: RFR: 8263080: Obsolete relationship in MulticastSocket API documentation. [v4]

2021-03-19 Thread Daniel Fuchs
nal capabilities for > joining "groups" of other multicast hosts on the internet." > > Not sure whether this requires a CSR. I guess not? 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

Re: RFR: 8263905: Remove finalize methods for SocketInput/OutputStream

2021-03-22 Thread Daniel Fuchs
On Mon, 22 Mar 2021 06:02:37 GMT, Kim Barrett wrote: > Please review this change to java.net.SocketInputStream and > java.net.SocketOutputStream, removing their "finalize" methods. These > methods are empty. Their purpose is to override and suppress the finalize > methods of their superclasses

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Daniel Fuchs
On Tue, 16 Mar 2021 14:19:09 GMT, Julia Boes wrote: > The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable > by wrapping it in an unmodifiable view. src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java line 34: > 32: public class UnmodifiableHea

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Daniel Fuchs
On Mon, 22 Mar 2021 16:30:10 GMT, Michael McMahon wrote: >> src/jdk.httpserver/share/classes/sun/net/httpserver/UnmodifiableHeaders.java >> line 34: >> >>> 32: public class UnmodifiableHeaders extends Headers { >>> 33: >>> 34: private Map> map; >> >> How about: >> >> private final He

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable

2021-03-22 Thread Daniel Fuchs
On Mon, 22 Mar 2021 16:25:24 GMT, Michael McMahon wrote: >> Headers normalizes the key before any get/getFirst, for example Headers line >> 131: >> >> `public List get(Object key) { >> return map.get(normalize((String)key)); >> }` >> >> I assume we want to maintain this beh

Integrated: 8263080: Obsolete relationship in MulticastSocket API documentation.

2021-03-23 Thread Daniel Fuchs
On Fri, 5 Mar 2021 11:09:37 GMT, Daniel Fuchs wrote: > Now that DatagramSocket has been updated by JDK-8237352 to support joining > multicast group, this sentence in the API class level documentation of > MulticastSocket is obsolete and should be removed: > > "A Multi

Re: RFR: 8263442: Potential bug in jdk.internal.net.http.common.Utils.CONTEXT_RESTRICTED [v3]

2021-03-23 Thread Daniel Fuchs
On Mon, 22 Mar 2021 22:16:09 GMT, Michael McMahon wrote: >> Hi, >> >> The fix for the reported bug in Utils.CONTEXT_RESTRICTED caused a couple of >> regression failures, which turned out to be another bug exposed by this fix >> where HTTP/1.1 CONNECT requests with authentication were filtering

Re: RFR: 8263442: Potential bug in jdk.internal.net.http.common.Utils.CONTEXT_RESTRICTED [v3]

2021-03-23 Thread Daniel Fuchs
On Mon, 22 Mar 2021 22:13:12 GMT, Michael McMahon wrote: >> What I am seeing is that if no authenticator set, whether the fix is present >> or not, an "Authorization" header is passed through, but a >> "Proxy-Authorization" header is filtered. So, that is a different issue. It >> probably is a

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head [v3]

2021-03-24 Thread Daniel Fuchs
On Mon, 22 Mar 2021 10:06:08 GMT, Michael McMahon wrote: >> Could I get the following simple fix reviewed please? >> >> The bug is jdk.internal.net.http.AuthenticationFilter throws an NPE wrapped >> in an IOException if it receives a HTTP response containing a >> WWW-Authenticate header with

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head [v4]

2021-03-24 Thread Daniel Fuchs
On Tue, 23 Mar 2021 13:45:06 GMT, Michael McMahon wrote: >> Could I get the following simple fix reviewed please? >> >> The bug is jdk.internal.net.http.AuthenticationFilter throws an NPE wrapped >> in an IOException if it receives a HTTP response containing a >> WWW-Authenticate header with

Re: RFR: 8263899: HttpClient throws NPE in AuthenticationFilter when parsing www-authenticate head [v3]

2021-03-24 Thread Daniel Fuchs
On Wed, 24 Mar 2021 11:06:47 GMT, Michael McMahon wrote: >> test/jdk/java/net/httpclient/EmptyAuthenticate.java line 63: >> >>> 61: //run client: >>> 62: try { >>> 63: HttpClient httpClient = HttpClient.newHttpClient(); >> >> Hmmm... Does this happen even when there'

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable [v2]

2021-03-29 Thread Daniel Fuchs
On Tue, 16 Mar 2021 14:35:12 GMT, Michael McMahon wrote: >> Julia Boes has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - wrap List with unmodifiable map and update test >> - remove map wrapping > > Changes requested by michaelm (Reviewe

Re: RFR: 8264048: Fix caching in Jar URL connections when an entry is missing

2021-03-31 Thread Daniel Fuchs
On Tue, 30 Mar 2021 11:30:48 GMT, Aleksei Efimov wrote: > Current fix tries to tackle an issue with URL connection referencing > non-existing Jar file entries: > If an entry that doesn't exist is specified in an URL connection the > underlying Jar file is still cached even if an exception is th

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable [v3]

2021-03-31 Thread Daniel Fuchs
On Wed, 31 Mar 2021 10:51:40 GMT, Julia Boes wrote: >> The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable >> by wrapping it in an unmodifiable view. > > Julia Boes has updated the pull request incrementally with one additional > commit since the last revision: > > m

Re: RFR: 8264048: Fix caching in Jar URL connections when an entry is missing [v2]

2021-04-01 Thread Daniel Fuchs
On Wed, 31 Mar 2021 12:47:50 GMT, Aleksei Efimov wrote: >> Current fix tries to tackle an issue with URL connection referencing >> non-existing Jar file entries: >> If an entry that doesn't exist is specified in an URL connection the >> underlying Jar file is still cached even if an exception i

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable [v4]

2021-04-06 Thread Daniel Fuchs
On Tue, 6 Apr 2021 13:10:59 GMT, Julia Boes wrote: >> The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable >> by wrapping it in an unmodifiable view. > > Julia Boes has updated the pull request with a new target base due to a merge > or a rebase. The incremental webrev e

Re: RFR: 8262898: com/sun/net/httpserver/bugs/8199849/ParamTest.java times out

2021-04-06 Thread Daniel Fuchs
On Tue, 6 Apr 2021 15:17:53 GMT, Michael McMahon wrote: > Hi, > > Could I get the following small test fix reviewed please? The test is timing > out on Mac probably because it is running on a system with a proxy that is > not bypassed for loopback connections. The test already sets NO_PROXY >

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable [v5]

2021-04-07 Thread Daniel Fuchs
On Wed, 7 Apr 2021 13:28:32 GMT, Julia Boes wrote: >> The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable >> by wrapping it in an unmodifiable view. > > Julia Boes has updated the pull request with a new target base due to a merge > or a rebase. The incremental webrev e

Re: RFR: 8263506: Make sun.net.httpserver.UnmodifiableHeaders unmodifiable [v6]

2021-04-07 Thread Daniel Fuchs
On Wed, 7 Apr 2021 17:02:28 GMT, Julia Boes wrote: >> The fix makes the map in sun.net.httpserver.UnmodifiableHeaders unmodifiable >> by wrapping it in an unmodifiable view. > > Julia Boes has updated the pull request incrementally with one additional > commit since the last revision: > > as

Re: RFR: 8264896: Remove redundant '& 0xFF' from int-to-byte cast

2021-04-08 Thread Daniel Fuchs
On Thu, 8 Apr 2021 08:54:35 GMT, Sebastian Stenzel wrote: >> When we do >> byte b1 = (byte) (value & 0xFF); >> we keep from int only 1 lower byte and exactly the same can be achieved with >> plain cast. See the test below: >> public class Main { >> public static void main(String[] args) throw

Re: RFR: 8264824: java/net/Inet6Address/B6206527.java doesn't close ServerSocket properly

2021-04-13 Thread Daniel Fuchs
On Tue, 13 Apr 2021 09:03:01 GMT, Michael McMahon wrote: >> ### Description >> `Inet6Address/B6206527.java` test creates two instances of ServerSocket, >> both of which are explicity bound to a Link-Local address. Neither of the >> ServerSocket instances are explicitly closed meaning there is n

Re: RFR: 8264824: java/net/Inet6Address/B6206527.java doesn't close ServerSocket properly [v2]

2021-04-13 Thread Daniel Fuchs
On Tue, 13 Apr 2021 10:30:18 GMT, Conor Cleary wrote: >> ### Description >> `Inet6Address/B6206527.java` test creates two instances of ServerSocket, >> both of which are explicity bound to a Link-Local address. Neither of the >> ServerSocket instances are explicitly closed meaning there is no g

Re: RFR: 8265123: Add static factory methods to com.sun.net.httpserver.Filter [v2]

2021-04-26 Thread Daniel Fuchs
On Mon, 26 Apr 2021 14:25:50 GMT, Julia Boes wrote: >> Add two static factory methods to com.sun.net.httpserver.Filter that >> facilitate the creation of pre- and post-processing Filters: >> >> `public static Filter beforeResponse(String description, >> Consumer filterImpl) {}` >> `public sta

Re: RFR: 8265123: Add static factory methods to com.sun.net.httpserver.Filter [v4]

2021-04-28 Thread Daniel Fuchs
On Wed, 28 Apr 2021 11:29:18 GMT, Julia Boes wrote: >> Add two static factory methods to com.sun.net.httpserver.Filter that >> facilitate the creation of pre- and post-processing Filters: >> >> `public static Filter beforeResponse(String description, >> Consumer filterImpl) {}` >> `public sta

Re: RFR: 8265123: Add static factory methods to com.sun.net.httpserver.Filter [v5]

2021-04-28 Thread Daniel Fuchs
On Wed, 28 Apr 2021 13:20:23 GMT, Julia Boes wrote: >> Add two static factory methods to com.sun.net.httpserver.Filter that >> facilitate the creation of pre- and post-processing Filters: >> >> `public static Filter beforeResponse(String description, >> Consumer filterImpl) {}` >> `public sta

Re: RFR: 8265123: Add static factory methods to com.sun.net.httpserver.Filter [v6]

2021-04-28 Thread Daniel Fuchs
On Wed, 28 Apr 2021 14:32:30 GMT, Julia Boes wrote: >> Add two static factory methods to com.sun.net.httpserver.Filter that >> facilitate the creation of pre- and post-processing Filters: >> >> `public static Filter beforeResponse(String description, >> Consumer filterImpl) {}` >> `public sta

RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List)

2021-04-28 Thread Daniel Fuchs
Please find here an almost trivial test fix that should improve diagnostic in case of failures. It also avoids relying on an unspecified behavior of `Assert.assertEquals`. - Commit messages: - 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List) Changes: ht

Re: RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List)

2021-04-29 Thread Daniel Fuchs
On 28/04/2021 23:51, Pavel Rappo wrote: On Wed, 28 Apr 2021 21:22:23 GMT, Daniel Fuchs wrote: It also avoids relying on an unspecified behavior of `Assert.assertEquals`. Which behavior is that? If I recall correctly, the test was written for TestNG 6.9.5, which provides a [method to

Re: RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List) [v2]

2021-04-29 Thread Daniel Fuchs
> Please find here an almost trivial test fix that should improve diagnostic in > case of failures. > It also avoids relying on an unspecified behavior of `Assert.assertEquals`. Daniel Fuchs has updated the pull request with a new target base due to a merge or a rebase. The increment

Re: RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List) [v3]

2021-04-29 Thread Daniel Fuchs
> Please find here an almost trivial test fix that should improve diagnostic in > case of failures. > It also avoids relying on an unspecified behavior of `Assert.assertEquals`. Daniel Fuchs has updated the pull request incrementally with one additional commit since the last

Re: RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List)

2021-04-29 Thread Daniel Fuchs
On Thu, 29 Apr 2021 10:25:39 GMT, Pavel Rappo wrote: >> On 28\/04\/2021 23\:51\, Pavel Rappo wrote\: >>> On Wed\, 28 Apr 2021 21\:22\:23 GMT\, Daniel Fuchs \>> openjdk\.org> wrote\: >>> >>>> It also avoids relying on an unspecified behavior of &

Re: RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List) [v4]

2021-04-29 Thread Daniel Fuchs
> Please find here an almost trivial test fix that should improve diagnostic in > case of failures. > It also avoids relying on an unspecified behavior of `Assert.assertEquals`. Daniel Fuchs has updated the pull request incrementally with one additional commit since the last

Re: RFR: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List) [v3]

2021-04-29 Thread Daniel Fuchs
On Thu, 29 Apr 2021 11:38:21 GMT, Pavel Rappo wrote: >> Daniel Fuchs has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Improved diagnostic message > > test/jdk/java/net/httpclient/websocket/WebSocketProx

Integrated: 8266250: WebSocketTest and WebSocketProxyTest call assertEquals(List, List)

2021-04-29 Thread Daniel Fuchs
On Wed, 28 Apr 2021 21:22:23 GMT, Daniel Fuchs wrote: > Please find here an almost trivial test fix that should improve diagnostic in > case of failures. > It also avoids relying on an unspecified behavior of `Assert.assertEquals`. This pull request has now been integrated.

RFR: 8255227: java/net/httpclient/FlowAdapterPublisherTest.java intermittently failing with TestServer: start exception: java.io.IOException: Invalid preface

2021-04-30 Thread Daniel Fuchs
Hi, I stumbled on an issue in Stream.java where an assert was misplaced, preventing the proper IOException to be triggered. I believe this is what caused the FlowAdapterPublisherTest.java to fail with the "Invalid Preface" error on the server side. In any case - I haven't observed this error a

Integrated: 8255227: java/net/httpclient/FlowAdapterPublisherTest.java intermittently failing with TestServer: start exception: java.io.IOException: Invalid preface

2021-04-30 Thread Daniel Fuchs
On Fri, 30 Apr 2021 10:46:33 GMT, Daniel Fuchs wrote: > Hi, > > I stumbled on an issue in Stream.java where an assert was misplaced, > preventing the proper IOException to be triggered. I believe this is what > caused the FlowAdapterPublisherTest.java to fail with the &

RFR: 8266761: AssertionError in sun.net.httpserver.ServerImpl.responseCompleted

2021-05-07 Thread Daniel Fuchs
Hi, Please find here a fix to prevent an assertion error from firing in the com.sun.net.httpserver. The issue occurs systematically when all of these conditions are met: 1. System assertions are enabled 2. The handler doesn't read or close the request input stream 3. The handler sends a reply w

Re: RFR: 8266761: AssertionError in sun.net.httpserver.ServerImpl.responseCompleted [v2]

2021-05-10 Thread Daniel Fuchs
rovided > system assertions are enabled) and passes with the fix. Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Added a second test case which triggers the assertion under different conditions - Changes: - a

Re: RFR: 8266761: AssertionError in sun.net.httpserver.ServerImpl.responseCompleted [v3]

2021-05-10 Thread Daniel Fuchs
rovided > system assertions are enabled) and passes with the fix. Daniel Fuchs has updated the pull request incrementally with one additional commit since the last revision: Removed obsolete comments - Changes: - all: https://git.openjdk.java.net/jdk/pull/3923/files - ne

Integrated: 8266761: AssertionError in sun.net.httpserver.ServerImpl.responseCompleted

2021-05-11 Thread Daniel Fuchs
On Fri, 7 May 2021 18:38:41 GMT, Daniel Fuchs wrote: > Hi, > > Please find here a fix to prevent an assertion error from firing in the > com.sun.net.httpserver. > > The issue occurs systematically when all of these conditions are met: > > 1. System assertions are

Re: RFR: 8266897: com/sun/net/httpserver/FilterTest.java fails intermittently with AssertionError

2021-05-17 Thread Daniel Fuchs
On Mon, 17 May 2021 09:53:06 GMT, Julia Boes wrote: > The tests for `afterHandler` filters expect the filter operation to happen > before the assertion. Very rarely this is not the case, the calling thread > reads the response before the filter operation is executed, so the test value > is not

Re: RFR: 8267184: JEP 411: Add -Djava.security.manager=allow to tests calling System.setSecurityManager

2021-05-18 Thread Daniel Fuchs
On Mon, 17 May 2021 17:51:36 GMT, Weijun Wang wrote: > Please review the test changes for [JEP > 411](https://openjdk.java.net/jeps/411). > > With JEP 411 and the default value of `-Djava.security.manager` becoming > `disallow`, tests calling `System.setSecurityManager()` need > `-Djava.secu

Re: RFR: 8267262: com/sun/net/httpserver/Filter improve API documentation of static methods

2021-05-19 Thread Daniel Fuchs
On Tue, 18 May 2021 09:34:25 GMT, Julia Boes wrote: > The filter operation `Consumer` that is passed to the factory methods can > throw an unchecked exception. This change adds a note on the exception > handling in that case. It also adds a clarification to `Filter::afterHandler` > on the rela

Re: RFR: 8267262: com/sun/net/httpserver/Filter improve API documentation of static methods

2021-05-19 Thread Daniel Fuchs
On Tue, 18 May 2021 09:34:25 GMT, Julia Boes wrote: > The filter operation `Consumer` that is passed to the factory methods can > throw an unchecked exception. This change adds a note on the exception > handling in that case. It also adds a clarification to `Filter::afterHandler` > on the rela

Re: Accessing 'system' header fields implicitly added by HttpClient

2021-05-21 Thread Daniel Fuchs
Hi Moataz, This sounds like a reasonable request, with a concrete use case. I have logged https://bugs.openjdk.java.net/browse/JDK-8267510 best regards, -- daniel On 20/05/2021 15:58, Moataz Abdelnasser wrote: Hi! I've recently released an HTTP cache (https://mizosoft.github.io/methanol/cac

Re: RFR: 8263561: Re-examine uses of LinkedList

2021-05-21 Thread Daniel Fuchs
On Fri, 26 Feb 2021 10:48:33 GMT, Сергей Цыпанов wrote: > The usage of `LinkedList` is senseless and can be replaced with either > `ArrayList` or `ArrayDeque` which are both more compact and effective. > > jdk:tier1 and jdk:tier2 are both ok I don't remember all the comments you have received

Re: RFR: 8266459: Implement JEP 411: Deprecate the Security Manager for Removal [v3]

2021-05-21 Thread Daniel Fuchs
On Wed, 19 May 2021 13:47:53 GMT, Weijun Wang wrote: >> Please review this implementation of [JEP >> 411](https://openjdk.java.net/jeps/411). >> >> The code change is divided into 3 commits. Please review them one by one. >> >> 1. >> https://github.com/openjdk/jdk/commit/576161d15423f58281e38

Re: RFR: 8267521: Post JEP 411 refactoring: maximum covering > 50K [v2]

2021-05-21 Thread Daniel Fuchs
On Fri, 21 May 2021 14:00:39 GMT, Weijun Wang wrote: >> The code change refactors classes that have a `SuppressWarnings("removal")` >> annotation that covers more than 50KB of code. The big annotation is often >> quite faraway from the actual deprecated API usage it is suppressing, and >> with

Re: RFR: JDK-8265362 java/net/Socket/UdpSocket.java fails with "java.net.BindException: Address already in use" (macos-aarch64)

2021-05-21 Thread Daniel Fuchs
On Tue, 18 May 2021 22:43:14 GMT, Mark Sheppard wrote: > The test java/net/Socket/UdpSocket.java has been seen to fail with a > BindException, in the testMaxSockets test, on a regular basis on > macOS-aarch64 platform. testMaxSockets tests the maximum number of UDP > Sockets that may be create

Re: RFR: 8267521: Post JEP 411 refactoring: maximum covering > 50K [v3]

2021-05-24 Thread Daniel Fuchs
On Fri, 21 May 2021 20:37:30 GMT, Weijun Wang wrote: >> The code change refactors classes that have a `SuppressWarnings("removal")` >> annotation that covers more than 50KB of code. The big annotation is often >> quite faraway from the actual deprecated API usage it is suppressing, and >> with

Re: RFR: 8267353: java/net/SctpSanity.java fails due to Protocol not supported

2021-05-26 Thread Daniel Fuchs
On Wed, 26 May 2021 03:54:14 GMT, Jie Fu wrote: > Hi all, > > java/net/SctpSanity.java fails on some of our test machines due to Protocol > not supported. > The reason is that the test fails to detect all the cases when a machine > doesn't support SCTP. > > The fix just follows what are done

RFR: 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with "IOException: No buffer space available"

2021-05-27 Thread Daniel Fuchs
Hi, Please find below a fix for: 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with "IOException: No buffer space available" The Pending* websocket tests create a server that accepts sockets to create a websocket, but never read data from the websocket in order to get the

Re: RFR: 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with "IOException: No buffer space available" [v2]

2021-05-27 Thread Daniel Fuchs
ose - which seemed to be failing more > frequently - to use smaller send and receive buffers in order to reach the > point at which the client bocks more quickly and avoid wasting system > resources. Daniel Fuchs has updated the pull request incrementally with two additional commits s

Re: RFR: 8267938: (sctp) SCTP channel factory methods should check platform support

2021-05-28 Thread Daniel Fuchs
On Fri, 28 May 2021 13:11:43 GMT, Chris Hegarty wrote: > The SCTP channel factory methods, namely SctpChannel::open, > SctpServerChannel::open, and SctpMultiChannel::open, are specified to throw > UnsupportedOperationException, if the SCTP protocol is not supported. > Currently, underlying pla

Integrated: 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with "IOException: No buffer space available"

2021-05-28 Thread Daniel Fuchs
On Thu, 27 May 2021 09:32:06 GMT, Daniel Fuchs wrote: > Hi, > > Please find below a fix for: > 8265367: [macos-aarch64] 3 java/net/httpclient/websocket tests fail with > "IOException: No buffer space available" > > The Pending* websocket tests create a server t

RFR: 8267990: Revisit some uses of `synchronized` in the HttpClient API

2021-05-31 Thread Daniel Fuchs
The Utils.remaining(List list) method assumes that it can and should synchronize on the given list to prevent concurrent modification. In 99% of the cases this assumption is wrong. There's only one such list (the SSLFlowDelegate writeList) that requires this synchronization. Also the `Sequenti

<    5   6   7   8   9   10   11   12   13   14   >