RFR: 8331195: Improve com.sun.net.httpserver.HttpExchange usability [v3]
Daniel Fuchs
dfuchs at openjdk.org
Tue Apr 30 15:43:07 UTC 2024
On Fri, 26 Apr 2024 15:37:13 GMT, robert engels <duke at openjdk.org> wrote:
>> improve the HttpExchange api with documented constants and convenience methods to avoid common bugs
>
> robert engels has updated the pull request incrementally with one additional commit since the last revision:
>
> Update src/jdk.httpserver/share/classes/com/sun/net/httpserver/HttpExchange.java
>
> Co-authored-by: Michael McMahon <70538289+Michael-Mc-Mahon at users.noreply.github.com>
src/jdk.httpserver/share/classes/com/sun/net/httpserver/HttpExchange.java line 237:
> 235: */
> 236: public final OutputStream sendResponseHeadersChunked(int code) throws IOException {
> 237: sendResponseHeaders(code,CHUNKED_CONTENT);
I don't like the fact that this methor returns an `OutputStream` when other `sendResponseXxx` methods return `void`. IMO it should either be renamed or the return type changed to `void`, or maybe it should simply be dropped.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/18955#discussion_r1585074446
More information about the net-dev
mailing list