Interface Http2ServerSettings
- All Known Subinterfaces:
Http2ServerSettings
- All Known Implementing Classes:
Http2ServerSettings.Http2ServerSettingsImpl
public interface Http2ServerSettings
-
Method Summary
Modifier and TypeMethodDescriptionintintintintintThe maximum time a connection is kept open before the server closes it gracefully.The time that requests in flight are given to complete after a connection reached the maximum connection age and the GOAWAY frame was sent.doubleThe jitter applied to the maximum connection age per connection, as a fraction of the configured age: with the default of 0.1 each connection is closed after between 90% and 110% of the configured age, so that connections that were opened together are not all closed at the same time. 0 disables jitter.intThe largest frame payload this endpoint accepts, in bytes.intThe maximum size of a decoded header list that this endpoint is prepared to accept, in bytes.intintbooleanintwithFrameTypeThrottleInterval(Duration interval) withIncomingConnectionLevelBufferSize(int newIncomingConnectionLevelBufferSize) withIncomingStreamLevelBufferSize(int newIncomingStreamLevelBufferSize) withLogFrames(boolean shouldLog) withMaxConcurrentStreams(int newValue) PassChronoUnit.FOREVER.getDurationto disable the maximum connection age.PassChronoUnit.FOREVER.getDurationfor an infinite grace period.withMaxConnectionAgeJitter(double jitter) withMaxFrameSize(int newValue) withMaxHeaderListSize(int newValue) withMinCollectStrictEntitySize(int newValue) withOutgoingControlFrameBufferSize(int newValue) withPingInterval(Duration interval) withPingTimeout(Duration timeout) withRequestEntityChunkSize(int newRequestEntityChunkSize)
-
Method Details
-
getRequestEntityChunkSize
int getRequestEntityChunkSize() -
withRequestEntityChunkSize
-
getIncomingConnectionLevelBufferSize
int getIncomingConnectionLevelBufferSize() -
withIncomingConnectionLevelBufferSize
-
getIncomingStreamLevelBufferSize
int getIncomingStreamLevelBufferSize() -
withIncomingStreamLevelBufferSize
-
minCollectStrictEntitySize
int minCollectStrictEntitySize() -
withMinCollectStrictEntitySize
-
getMaxConcurrentStreams
int getMaxConcurrentStreams() -
withMaxConcurrentStreams
-
getMaxHeaderListSize
int getMaxHeaderListSize()The maximum size of a decoded header list that this endpoint is prepared to accept, in bytes. The value is advertised to the peer via SETTINGS_MAX_HEADER_LIST_SIZE and the same limit is applied to the accumulated header block fragments of a HEADERS frame and its CONTINUATION frames.- Returns:
- (undocumented)
- Since:
- 1.4.1
-
withMaxHeaderListSize
- Parameters:
newValue- (undocumented)- Returns:
- (undocumented)
- Since:
- 1.4.1
-
getMaxFrameSize
int getMaxFrameSize()The largest frame payload this endpoint accepts, in bytes. A larger incoming frame is rejected with a FRAME_SIZE_ERROR on its frame header, before the payload is buffered. No larger SETTINGS_MAX_FRAME_SIZE is advertised, so a peer that follows the spec keeps to the 16 KiB default and the extra room is leniency for peers that do not. RFC 9113, section 4.2 constrains it to be between 16 KiB and 16 MiB - 1.- Returns:
- (undocumented)
- Since:
- 2.0.0
-
withMaxFrameSize
- Parameters:
newValue- (undocumented)- Returns:
- (undocumented)
- Since:
- 2.0.0
-
getOutgoingControlFrameBufferSize
int getOutgoingControlFrameBufferSize() -
withOutgoingControlFrameBufferSize
-
logFrames
boolean logFrames() -
withLogFrames
-
getPingInterval
Duration getPingInterval() -
withPingInterval
-
getPingTimeout
Duration getPingTimeout() -
withPingTimeout
-
getMaxConnectionAge
Duration getMaxConnectionAge()The maximum time a connection is kept open before the server closes it gracefully. When the age of a connection exceeds this value, the server sends a GOAWAY frame, lets requests that are already in flight complete withingetMaxConnectionAgeGrace(), and then closes the connection. If the connection is already being terminated when its age expires, for example because the server binding is being terminated, the expiry has no effect and the termination in progress keeps its own deadline. The valueChronoUnit.FOREVER.getDurationrepresents an infinite age, which disables this mechanism and is the default.- Returns:
- (undocumented)
- Since:
- 2.0.0
-
withMaxConnectionAge
PassChronoUnit.FOREVER.getDurationto disable the maximum connection age.- Parameters:
age- (undocumented)- Returns:
- (undocumented)
- Since:
- 2.0.0
-
getMaxConnectionAgeGrace
Duration getMaxConnectionAgeGrace()The time that requests in flight are given to complete after a connection reached the maximum connection age and the GOAWAY frame was sent. When the grace period expires, the connection is closed even if requests are still in flight. The valueChronoUnit.FOREVER.getDurationrepresents an infinite grace period, which disables the limit, so that the connection is closed only once all requests in flight have completed.- Returns:
- (undocumented)
- Since:
- 2.0.0
-
withMaxConnectionAgeGrace
PassChronoUnit.FOREVER.getDurationfor an infinite grace period.- Parameters:
grace- (undocumented)- Returns:
- (undocumented)
- Since:
- 2.0.0
-
getMaxConnectionAgeJitter
double getMaxConnectionAgeJitter()The jitter applied to the maximum connection age per connection, as a fraction of the configured age: with the default of 0.1 each connection is closed after between 90% and 110% of the configured age, so that connections that were opened together are not all closed at the same time. 0 disables jitter.- Returns:
- (undocumented)
- Since:
- 2.0.0
-
withMaxConnectionAgeJitter
- Parameters:
jitter- (undocumented)- Returns:
- (undocumented)
- Since:
- 2.0.0
-
getFrameTypeThrottleFrameTypes
-
getFrameTypeThrottleCost
int getFrameTypeThrottleCost() -
getFrameTypeThrottleBurst
int getFrameTypeThrottleBurst() -
getFrameTypeThrottleInterval
Duration getFrameTypeThrottleInterval() -
withFrameTypeThrottleInterval
-