RFR: 8163921: HttpURLConnection default Accept header is malformed according to HTTP/1.1 RFC [v2]

Michael McMahon michaelm at openjdk.java.net
Mon Jan 24 15:25:15 UTC 2022


On Mon, 24 Jan 2022 14:38:02 GMT, Michael McMahon <michaelm at openjdk.org> wrote:

>> Daniel Jeliński has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Update copyright year
>
> src/java.base/share/classes/sun/net/www/protocol/http/HttpURLConnection.java line 293:
> 
>> 291:     static final String acceptString =
>> 292:         "text/html, image/gif, image/jpeg, */*; q=0.2";
>> 293: 
> 
> It looks syntactically correct now, but I wonder about the actual semantics, and whether it makes any sense to be asking for 80% reduction in quality of other media types.

Should we just have `static final String acceptString = "*/*";`

-------------

PR: https://git.openjdk.java.net/jdk/pull/7181


More information about the net-dev mailing list