On Fri, 29 Jan 2021 11:03:07 GMT, Evan Whelan <ewhe...@openjdk.org> wrote:
>> Hi all, >> >> Please review this fix for which corrects the order in which field values >> are returned from the `HttpURLConnection.getHeaderFields` and >> `URLConnection.getRequestProperties` methods. >> >> Currently, the implementation of these methods returns the values in >> reverse. This does not conform with the RFC2616 spec which outlines that the >> order of these field values should not be changed. >> >> Thanks, >> Evan > > Evan Whelan has updated the pull request incrementally with one additional > commit since the last revision: > > URLConnection doc fixes Changes requested by chegar (Reviewer). src/java.base/share/classes/java/net/URLConnection.java line 1147: > 1145: * to the map is not supported by the protocol being > 1146: * used in a given subclass. > 1147: * I'm not sure about this. What is the use-case driving this clarification? Is it just for the corner case where the default implementation of getHeaderFields is not overridden ? src/java.base/share/classes/java/net/URLConnection.java line 1200: > 1198: * added. This method must preserve the insertion order > 1199: * of such values. > 1200: * But we have made addRequestProperty effectively a no-op ( as above ) ! ------------- PR: https://git.openjdk.java.net/jdk/pull/2294