Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v11]

2020-11-19 Thread Michael McMahon
On Wed, 18 Nov 2020 17:45:25 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v11]

2020-11-18 Thread Daniel Fuchs
On Wed, 18 Nov 2020 17:45:25 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v11]

2020-11-18 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v10]

2020-11-18 Thread Daniel Fuchs
On Wed, 18 Nov 2020 12:23:15 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-18 Thread Patrick Concannon
On Tue, 17 Nov 2020 16:50:46 GMT, Daniel Fuchs wrote: >> Would it be enough to check in each test case that if we are examining a >> request with headers, it contains at least one called `testName1`? i.e. >> if(!request.headers().map().isEmpty()) >> assertTrue(request.headers

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-18 Thread Patrick Concannon
On Tue, 17 Nov 2020 18:28:46 GMT, Daniel Fuchs wrote: >> Ah! Good catch - I believe the code is buggy. It should have been >> `!name.equalsIgnoreCase(...)`. > > Patrick - can you add a test case with exactly **that** use case? I know you > have similar tests which remove `"testName1"`, but it w

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-18 Thread Patrick Concannon
On Mon, 16 Nov 2020 17:23:42 GMT, Daniel Fuchs wrote: >> Patrick Concannon 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 contains 15 additional >> comm

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v10]

2020-11-18 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v9]

2020-11-18 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-17 Thread Daniel Fuchs
On Tue, 17 Nov 2020 17:28:45 GMT, Daniel Fuchs wrote: >> src/java.net.http/share/classes/java/net/http/HttpRequest.java line 335: >> >>> 333: * Remove a particular header (e.g. Foo-Bar): >>> 334: * {@code HttpRequest.newBuilder(request, (name, value) -> >>> name.equalsIgnoreCase("F

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-17 Thread Daniel Fuchs
On Tue, 17 Nov 2020 17:16:48 GMT, Michael McMahon wrote: >> Patrick Concannon 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 contains 15 additional >> c

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-17 Thread Michael McMahon
On Mon, 16 Nov 2020 15:54:18 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-17 Thread Chris Hegarty
On Mon, 16 Nov 2020 15:54:18 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-17 Thread Daniel Fuchs
On Tue, 17 Nov 2020 16:16:53 GMT, Patrick Concannon wrote: >> test/jdk/java/net/httpclient/HttpRequestNewBuilderTest.java line 320: >> >>> 318: @Test(dataProvider = "testRequests") >>> 319: public void testRemoveHeader(HttpRequest request) { >>> 320: BiPredicate filter = (n, v)

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-17 Thread Patrick Concannon
On Mon, 16 Nov 2020 17:29:20 GMT, Daniel Fuchs wrote: >> Patrick Concannon 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 contains 15 additional >> comm

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-16 Thread Daniel Fuchs
On Mon, 16 Nov 2020 15:54:18 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v6]

2020-11-16 Thread Patrick Concannon
On Fri, 13 Nov 2020 17:16:21 GMT, Daniel Fuchs wrote: >> test/jdk/java/net/httpclient/HttpRequestNewBuilderTest.java line 171: >> >>> 169: while (iter1.hasNext() && iter2.hasNext()) >>> 170: assertEquals(iter1.next(), iter2.next()); >>> 171: } >> >> This code doesn't see

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v8]

2020-11-16 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v7]

2020-11-16 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v6]

2020-11-13 Thread Daniel Fuchs
On Fri, 13 Nov 2020 16:45:31 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existi

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v6]

2020-11-13 Thread Daniel Fuchs
On Fri, 13 Nov 2020 17:21:02 GMT, Daniel Fuchs wrote: >> Patrick Concannon 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 contains 12 additional >> comm

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v6]

2020-11-13 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v5]

2020-11-13 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-09 Thread Mark Sheppard
On Mon, 9 Nov 2020 18:38:33 GMT, Mark Sheppard wrote: >> I wonder if the spec should be a little more specific than just "seeded" >> which I think is fine for the first sentence. But maybe say something like >> "fields are copied from the given HttpRequest" in the description. > > a couple of p

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-09 Thread Daniel Fuchs
Hi Mark, On 09/11/2020 18:40, Mark Sheppard wrote: a couple of points: Should the spec state explicitly that an NPE is thrown if the supplied HttpRequest reference is null? https://docs.oracle.com/en/java/javase/15/docs/api/java.net.http/java/net/http/package-summary.html "Unless otherwise s

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-09 Thread Mark Sheppard
On Mon, 9 Nov 2020 10:28:08 GMT, Michael McMahon wrote: >>> /csr >> >> Link to CSR: https://bugs.openjdk.java.net/browse/JDK-8255993 > > I wonder if the spec should be a little more specific than just "seeded" > which I think is fine for the first sentence. But maybe say something like > "fiel

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-09 Thread Michael McMahon
On Fri, 6 Nov 2020 18:09:01 GMT, Patrick Concannon wrote: >> Marked as reviewed by chegar (Reviewer). > >> /csr > > Link to CSR: https://bugs.openjdk.java.net/browse/JDK-8255993 I wonder if the spec should be a little more specific than just "seeded" which I think is fine for the first senten

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v4]

2020-11-09 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-06 Thread Patrick Concannon
On Thu, 5 Nov 2020 17:17:14 GMT, Chris Hegarty wrote: >> Patrick Concannon 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 contains six additional >> com

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-05 Thread Chris Hegarty
On Thu, 5 Nov 2020 16:23:13 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existin

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-05 Thread Daniel Fuchs
On Thu, 5 Nov 2020 16:23:13 GMT, Patrick Concannon wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existin

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-05 Thread Patrick Concannon
On Wed, 4 Nov 2020 15:11:50 GMT, Daniel Fuchs wrote: >> Patrick Concannon 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 contains six additional >> comm

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-05 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-05 Thread Patrick Concannon
On Wed, 4 Nov 2020 15:04:35 GMT, Chris Hegarty wrote: >> Patrick Concannon 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 contains six additional >> com

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v3]

2020-11-05 Thread Patrick Concannon
On Wed, 4 Nov 2020 15:42:54 GMT, Daniel Fuchs wrote: >> src/java.net.http/share/classes/java/net/http/HttpRequest.java line 344: >> >>> 342: throw ex; >>> 343: } catch (RuntimeException r) { >>> 344: throw new IllegalArgumentException("Illegal request >>> paramet

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest [v2]

2020-11-05 Thread Patrick Concannon
> Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `HttpRequest`. > This method can be used to build a new request eq

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest

2020-11-04 Thread Daniel Fuchs
On Wed, 4 Nov 2020 15:18:01 GMT, Chris Hegarty wrote: >> Hi, >> >> Could someone please review our code for JDK-8252304: 'Seed an >> HttpRequest.Builder from an existing HttpRequest'? >> >> This RFR proposes a new factory method for creating a new `HttpRequest` >> builder from an existing `Ht

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest

2020-11-04 Thread Daniel Fuchs
On Wed, 4 Nov 2020 14:51:07 GMT, Patrick Concannon wrote: > Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `Http

Re: RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest

2020-11-04 Thread Chris Hegarty
On Wed, 4 Nov 2020 14:51:07 GMT, Patrick Concannon wrote: > Hi, > > Could someone please review our code for JDK-8252304: 'Seed an > HttpRequest.Builder from an existing HttpRequest'? > > This RFR proposes a new factory method for creating a new `HttpRequest` > builder from an existing `Http

RFR: 8252304: Seed an HttpRequest.Builder from an existing HttpRequest

2020-11-04 Thread Patrick Concannon
Hi, Could someone please review our code for JDK-8252304: 'Seed an HttpRequest.Builder from an existing HttpRequest'? This RFR proposes a new factory method for creating a new `HttpRequest` builder from an existing `HttpRequest`. This method can be used to build a new request equivalent to the