Re: java.net.http.HttpClient Redirect Policy

2019-10-18 Thread Daniel Fuchs
Hi Eliot, On 04/10/2019 22:13, Elliot Barlas wrote: Why is HttpClient behaving this way? Browsers certainly doin't do this. Am I missing a config option? Thanks for reporting this. I believe this is a bug - I have logged https://bugs.openjdk.java.net/browse/JDK-8232625 In the mean time - I'd

java.net.http.HttpClient Redirect Policy

2019-10-18 Thread Elliot Barlas
Net-dev, I'm attempting to use java.net.http.HttpClient to make a login form submission and follow a sequence of redirects. To my surprise, the HttpClient redirect internals (jdk.internal.net.http.HttpRequestImpl) seem to carry the original request body into subsequent requests. In my case, that

Re: RFR: 8231632: HttpURLConnection::usingProxy could specify that it may lazily evaluate the fact

2019-10-18 Thread Julia Boes
Thanks all! Here's CSR for the fix: https://bugs.openjdk.java.net/browse/JDK-8232600

Re: RFR: 8231632: HttpURLConnection::usingProxy could specify that it may lazily evaluate the fact

2019-10-18 Thread Chris Hegarty
> On 18 Oct 2019, at 15:30, Julia Boes wrote: > > > 1) Maybe add @Override to `public boolean usingProxy()`. ( pre-existing issue > ) > > 2) Maybe move the return on 3040 to a new line. Also use the curly braces > consistently, or not at all ;-) > > That's right! Thanks for reviewing, Chr

Re: RFR: 8231632: HttpURLConnection::usingProxy could specify that it may lazily evaluate the fact

2019-10-18 Thread Julia Boes
1) Maybe add @Override to `public boolean usingProxy()`. ( pre-existing issue ) 2) Maybe move the return on 3040 to a new line. Also use the curly braces consistently, or not at all ;-) That's right! Thanks for reviewing, Chris. I added those two changes. Updated webrev: http://cr.openjdk.j

Re: RFR: 8231632: HttpURLConnection::usingProxy could specify that it may lazily evaluate the fact

2019-10-18 Thread Chris Hegarty
> On 18 Oct 2019, at 10:02, Julia Boes wrote: > > Hi, > > Chris and Daniel provided some off-list feedback regarding the > ProxySelector::select call. It returns a list of proxies, which could be > dynamic. Each call can potentially return a different list of proxies so it's > not desirable

Re: RFR: 8231632: HttpURLConnection::usingProxy could specify that it may lazily evaluate the fact

2019-10-18 Thread Julia Boes
Hi, Chris and Daniel provided some off-list feedback regarding the ProxySelector::select call. It returns a list of proxies, which could be dynamic. Each call can potentially return a different list of proxies so it's not desirable to make that call twice. An alternative is to maintain a clas