RFR [14] 8225583: Examine the HttpResponse.BodySubscribers for null handling

2019-06-13 Thread Chris Hegarty
The convenience BodySubscriber implementations in HttpResponse.BodySubscribers should consistently throw NPE when passed a null value. https://cr.openjdk.java.net/~chegar/8225583/webrev.00/ -Chris.

Re: RFR [14] 8225583: Examine the HttpResponse.BodySubscribers for null handling

2019-06-13 Thread Daniel Fuchs
Thanks Chris! That's a nice cleanup. Reviewed. -- daniel On 13/06/2019 09:39, Chris Hegarty wrote: The convenience BodySubscriber implementations in HttpResponse.BodySubscribers should consistently throw NPE when passed a null value. https://cr.openjdk.java.net/~chegar/8225583/webrev.00/ -C

Re: [PATCH] JDK-8217705 - HTTPClient wrong exception type when bad status line is received

2019-06-13 Thread Daniel Fuchs
Hi Jaikiran, On 12/06/2019 16:01, Jaikiran Pai wrote: The new webrev is now available for review at http://cr.openjdk.java.net/~jpai/8217705/01/webrev/ I'm happy to report that tests have been successful. Can you regenerate the webrev so that it has a changeset that can be hg imported? I susp

Re: RFR [14] 8225583: Examine the HttpResponse.BodySubscribers for null handling

2019-06-13 Thread Pavel Rappo
Given the changes in PublishingBodySubscriber.onError, do we still need this null check? 884 private void signalError(Throwable err) { 885 if (err == null) { 886 err = new NullPointerException("null throwable"); 887 } 888 completionCF.com

Re: RFR [14] 8225583: Examine the HttpResponse.BodySubscribers for null handling

2019-06-13 Thread Daniel Fuchs
Hi Pavel, Good catch, but I'd say yes. I think would object to removing it. I'd prefer to remove: 958 Objects.requireNonNull(throwable); cheers, -- daniel On 13/06/2019 17:40, Pavel Rappo wrote: Given the changes in PublishingBodySubscriber.onError, do we still need this null ch

Re: RFR [14] 8225583: Examine the HttpResponse.BodySubscribers for null handling

2019-06-13 Thread Pavel Rappo
> On 13 Jun 2019, at 17:57, Daniel Fuchs wrote: > > I'd prefer to remove: > 958 Objects.requireNonNull(throwable); But it seems to be the crux of that change. The tests accompanying this change verifies that behavior.

Re: RFR [14] 8225583: Examine the HttpResponse.BodySubscribers for null handling

2019-06-13 Thread Daniel Fuchs
On 13/06/2019 18:04, Pavel Rappo wrote: On 13 Jun 2019, at 17:57, Daniel Fuchs wrote: I'd prefer to remove: 958 Objects.requireNonNull(throwable); But it seems to be the crux of that change. The tests accompanying this change verifies that behavior. That line is not needed since

Re: [PATCH] JDK-8217705 - HTTPClient wrong exception type when bad status line is received

2019-06-13 Thread Jaikiran Pai
Hello Daniel, On 13/06/19 7:11 PM, Daniel Fuchs wrote: > Hi Jaikiran, > > On 12/06/2019 16:01, Jaikiran Pai wrote: >> The new webrev is now available for review at >> http://cr.openjdk.java.net/~jpai/8217705/01/webrev/ > > I'm happy to report that tests have been successful. Good to hear and thank