Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default header size increased to 16K - Helidon 3.x #5016

Merged
merged 4 commits into from
Sep 30, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/config/io_helidon_webserver_SocketConfiguration.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Type: link:{javadoc-base-url}/io.helidon.webserver/io/helidon/webserver/SocketCo

Default is `false`
|`host` |string |{nbsp} |A helper method that just calls #bindAddress(String).
|`max-header-size` |int |`8192` |Maximal number of bytes of all header values combined. When a bigger value is received, a
|`max-header-size` |int |`16384` |Maximal number of bytes of all header values combined. When a bigger value is received, a
io.helidon.common.http.Http.Status#BAD_REQUEST_400
is returned.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Type: link:{javadoc-base-url}/io.helidon.webserver.SocketConfiguration/io/helido

Default is `false`
|`host` |string |{nbsp} |A helper method that just calls #bindAddress(String).
|`max-header-size` |int |`8192` |Maximal number of bytes of all header values combined. When a bigger value is received, a
|`max-header-size` |int |`16384` |Maximal number of bytes of all header values combined. When a bigger value is received, a
io.helidon.common.http.Http.Status#BAD_REQUEST_400
is returned.

Expand Down
2 changes: 1 addition & 1 deletion docs/config/io_helidon_webserver_WebServer.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ This is a standalone configuration type, prefix from configuration root: `server
Default is `false`
|`features.print-details` |boolean |`false` |Set to `true` to print detailed feature information on startup.
|`host` |string |{nbsp} |A helper method that just calls #bindAddress(String).
|`max-header-size` |int |`8192` |Maximal number of bytes of all header values combined. When a bigger value is received, a
|`max-header-size` |int |`16384` |Maximal number of bytes of all header values combined. When a bigger value is received, a
io.helidon.common.http.Http.Status#BAD_REQUEST_400
is returned.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -363,12 +363,12 @@ default B tls(Supplier<WebServerTls> tlsConfig) {
* {@link io.helidon.common.http.Http.Status#BAD_REQUEST_400}
* is returned.
* <p>
* Default is {@code 8192}
* Default is {@code 16384}
*
* @param size maximal number of bytes of combined header values
* @return this builder
*/
@ConfiguredOption("8192")
@ConfiguredOption("16384")
B maxHeaderSize(int size);

/**
Expand Down Expand Up @@ -483,8 +483,9 @@ final class Builder implements SocketConfigurationBuilder<Builder>, io.helidon.c
// methods with `name` are removed from server builder (for adding sockets)
private String name = UNCONFIGURED_NAME;
private boolean enabled = true;
// header size doubled comparing to default netty size
private int maxHeaderSize = 16384;
// these values are as defined in Netty implementation
private int maxHeaderSize = 8192;
private int maxInitialLineLength = 4096;
private int maxChunkSize = 8192;
private boolean validateHeaders = true;
Expand Down