Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-20 Thread Andreas Rieber
On 20.06.13 12:55, Chris Hegarty wrote: On 06/20/2013 10:33 AM, Andreas Rieber wrote: I see, short test without leading "/" in the path causes the httpserver to throws exception: Exception in thread "main" java.lang.IllegalArgumentException: Illegal value for path or protocol at sun.net.ht

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-20 Thread Chris Hegarty
On 06/20/2013 10:33 AM, Andreas Rieber wrote: I see, short test without leading "/" in the path causes the httpserver to throws exception: Exception in thread "main" java.lang.IllegalArgumentException: Illegal value for path or protocol at sun.net.httpserver.HttpContextImpl.(HttpContextImpl

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-20 Thread Andreas Rieber
I see, short test without leading "/" in the path causes the httpserver to throws exception: Exception in thread "main" java.lang.IllegalArgumentException: Illegal value for path or protocol at sun.net.httpserver.HttpContextImpl.(HttpContextImpl.java:60) at sun.net.httpserver.S

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-20 Thread Andreas Rieber
Yea, i saw the push and was missing the flowers ;-) For the extra credits i might have some more issues on HttpUrlConnection i could do with your help. And ok, just searched for httpserver on bugs.sun.com -> results in 249... Will check what i could do there. cheers Andreas On 20.06.13 10:4

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-20 Thread Chris Hegarty
I see Kurchi pushed this change for you. http://hg.openjdk.java.net/jdk8/tl/jdk/rev/2b156531b7eb For extra credits ;-) does it make sense to something similar on the server side, sun.net.httpserver??? -Chris. On 06/19/2013 07:29 PM, Andreas Rieber wrote: Hi Kurchi, to change the path in U

hg: jdk8/tl/jdk: 7025238: HttpURLConnection does not handle URLs with an empty path component.

2013-06-19 Thread kurchi . subhra . hazra
Changeset: 2b156531b7eb Author:arieber Date: 2013-06-19 17:41 -0700 URL: http://hg.openjdk.java.net/jdk8/tl/jdk/rev/2b156531b7eb 7025238: HttpURLConnection does not handle URLs with an empty path component. Summary: Prepend a '/' to file when path is empty Reviewed-

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-19 Thread Kurchi Hazra
Hi Andreas, I was not talking about changing the URL implementation, but just pointing out that your change doesn't cause incompatibilities in the way we store elements in the cookiehandler, which is good. I ran all networking tests on all supported platforms, and things look green. I'll push

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-19 Thread Andreas Rieber
Hi Kurchi, to change the path in URL.java would not be a good idea, it supports many other protocols as well and what i can read out of the URL specification is that path can be empty. True, ParserUtil.toUri() uses the path and query elements separate. Here in HttpClient.java i guess it saves

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-19 Thread Kurchi Hazra
Hi Andreas, I looked at your changes, and they look good to me. Although we are not changing the path of the URL itself (it is not modifiable too), but from what I see the only other relevant place where URL.path is logically used in http client is in ParseUtil.toURI(), which basically does

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-19 Thread Andreas Rieber
Hi Chris and Kurchi, i have updated and rerun the test (removed the "@run main/othervm B7025238"). New webrev is here: http://cr.openjdk.java.net/~arieber/7025238/webrev.01/ thanks Andreas On 19.06.13 15:33, Chris Hegarty wrote: Hi Andreas, On 18/06/2013 20:19, Andreas Rieber wrote: Hi,

Re: 7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-19 Thread Chris Hegarty
Hi Andreas, On 18/06/2013 20:19, Andreas Rieber wrote: Hi, i am looking for a sponsor of this issue. The bug is here: http://bugs.sun.com/view_bug.do?bug_id=7025238 First i verified that the problem still exists. Then i checked the problem against some other web servers. Apache handles a miss

7025238 : HttpURLConnection does not handle URLs with an empty path component

2013-06-18 Thread Andreas Rieber
Hi, i am looking for a sponsor of this issue. The bug is here: http://bugs.sun.com/view_bug.do?bug_id=7025238 First i verified that the problem still exists. Then i checked the problem against some other web servers. Apache handles a missing "/" in the path. Tomcat, Microsoft-HTTPAPI/2.0 and