Home / Type/ Http2HeadersDecoder Type — netty Architecture

Http2HeadersDecoder Type — netty Architecture

Architecture documentation for the Http2HeadersDecoder type/interface in Http2HeadersDecoder.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  5c73663b_310e_f4d7_b8af_51d3f8b42d4d["Http2HeadersDecoder"]
  ad1853a9_8f28_f901_e524_ebf097c1dc24["Http2HeadersDecoder.java"]
  5c73663b_310e_f4d7_b8af_51d3f8b42d4d -->|defined in| ad1853a9_8f28_f901_e524_ebf097c1dc24
  style 5c73663b_310e_f4d7_b8af_51d3f8b42d4d fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http2/src/main/java/io/netty/handler/codec/http2/Http2HeadersDecoder.java lines 23–78

public interface Http2HeadersDecoder {
    /**
     * Configuration related elements for the {@link Http2HeadersDecoder} interface
     */
    interface Configuration {
        /**
         * Represents the value for
         * <a href="https://tools.ietf.org/html/rfc7540#section-6.5.2">SETTINGS_HEADER_TABLE_SIZE</a>.
         * This method should only be called by Netty (not users) as a result of a receiving a {@code SETTINGS} frame.
         */
        void maxHeaderTableSize(long max) throws Http2Exception;

        /**
         * Represents the value for
         * <a href="https://tools.ietf.org/html/rfc7540#section-6.5.2">SETTINGS_HEADER_TABLE_SIZE</a>. The initial value
         * returned by this method must be {@link Http2CodecUtil#DEFAULT_HEADER_TABLE_SIZE}.
         */
        long maxHeaderTableSize();

        /**
         * Configure the maximum allowed size in bytes of each set of headers.
         * <p>
         * This method should only be called by Netty (not users) as a result of a receiving a {@code SETTINGS} frame.
         * @param max <a href="https://tools.ietf.org/html/rfc7540#section-6.5.2">SETTINGS_MAX_HEADER_LIST_SIZE</a>.
         *      If this limit is exceeded the implementation should attempt to keep the HPACK header tables up to date
         *      by processing data from the peer, but a {@code RST_STREAM} frame will be sent for the offending stream.
         * @param goAwayMax Must be {@code >= max}. A {@code GO_AWAY} frame will be generated if this limit is exceeded
         *                  for any particular stream.
         * @throws Http2Exception if limits exceed the RFC's boundaries or {@code max > goAwayMax}.
         */
        void maxHeaderListSize(long max, long goAwayMax) throws Http2Exception;

        /**
         * Represents the value for
         * <a href="https://tools.ietf.org/html/rfc7540#section-6.5.2">SETTINGS_MAX_HEADER_LIST_SIZE</a>.
         */
        long maxHeaderListSize();

        /**
         * Represents the upper bound in bytes for a set of headers before a {@code GO_AWAY} should be sent.
         * This will be {@code <=}
         * <a href="https://tools.ietf.org/html/rfc7540#section-6.5.2">SETTINGS_MAX_HEADER_LIST_SIZE</a>.
         */
        long maxHeaderListSizeGoAway();
    }

    /**
     * Decodes the given headers block and returns the headers.
     */
    Http2Headers decodeHeaders(int streamId, ByteBuf headerBlock) throws Http2Exception;

    /**
     * Get the {@link Configuration} for this {@link Http2HeadersDecoder}
     */
    Configuration configuration();
}

Frequently Asked Questions

What is the Http2HeadersDecoder type?
Http2HeadersDecoder is a type/interface in the netty codebase, defined in codec-http2/src/main/java/io/netty/handler/codec/http2/Http2HeadersDecoder.java.
Where is Http2HeadersDecoder defined?
Http2HeadersDecoder is defined in codec-http2/src/main/java/io/netty/handler/codec/http2/Http2HeadersDecoder.java at line 23.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free