DecoratingHttp2ConnectionEncoder which guards against a remote peer that will trigger a massive amount
of control frames but will not consume our responses to these.
This encoder will tear-down the connection once we reached the configured limit to reduce the risk of DDOS.
| Modifier and Type | Field and Description |
|---|---|
| private Http2LifecycleManager | |
| private boolean | |
| private static final InternalLogger | |
| private final int | |
| private int | |
| private final FutureListener |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| private FutureListener | |
| public void | lifecycleManager(Http2LifecycleManager lifecycleManager)
Overrides io. Implements io. |
| public Future | writePing(ChannelHandlerContext
the context to use for writing. ctx, boolean indicates whether this is an ack of a PING frame previously received from the
remote endpoint. ack, long the payload of the frame. data)Overrides io. Implements io. |
| public Future | writeRstStream(ChannelHandlerContext
the context to use for writing. ctx, int the stream for which to send the frame. streamId, long the error code indicating the nature of the failure. errorCode)Overrides io. Implements io. |
| public Future | writeSettingsAck(ChannelHandlerContext
the context to use for writing. ctx)Overrides io. Implements io. |
| lifecycleManager | back to summary |
|---|---|
| private Http2LifecycleManager lifecycleManager | |
| limitReached | back to summary |
|---|---|
| private boolean limitReached | |
| logger | back to summary |
|---|---|
| private static final InternalLogger logger | |
| maxOutstandingControlFrames | back to summary |
|---|---|
| private final int maxOutstandingControlFrames | |
| outstandingControlFrames | back to summary |
|---|---|
| private int outstandingControlFrames | |
| outstandingControlFramesListener | back to summary |
|---|---|
| private final FutureListener<Void> outstandingControlFramesListener | |
| Http2ControlFrameLimitEncoder | back to summary |
|---|---|
| pack-priv Http2ControlFrameLimitEncoder(Http2ConnectionEncoder delegate, int maxOutstandingControlFrames) | |
| handleOutstandingControlFrames | back to summary |
|---|---|
| private FutureListener | |
| lifecycleManager | back to summary |
|---|---|
| public void lifecycleManager(Http2LifecycleManager lifecycleManager) Overrides io. Implements io. Doc from io. Sets the lifecycle manager. Must be called as part of initialization before the encoder is used.
| |
| writePing | back to summary |
|---|---|
| public Future Overrides io. Implements io. Doc from io. Writes a PING frame to the remote endpoint.
| |
| writeRstStream | back to summary |
|---|---|
| public Future Overrides io. Implements io. Doc from io. Writes a RST_STREAM frame to the remote endpoint.
| |
| writeSettingsAck | back to summary |
|---|---|
| public Future Overrides io. Implements io. Doc from io. Writes a SETTINGS acknowledgment to the remote endpoint.
| |