HttpConversionUtil Class — netty Architecture
Architecture documentation for the HttpConversionUtil class in HttpConversionUtil.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 0560b510_c1dc_0a46_6dca_e5dbfb67d807["HttpConversionUtil"] c9afade8_db3e_8af8_f9ef_81beb249ccd9["HttpConversionUtil.java"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|defined in| c9afade8_db3e_8af8_f9ef_81beb249ccd9 5f12a632_5a6b_7109_77cd_c238cccac3a0["HttpConversionUtil()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 5f12a632_5a6b_7109_77cd_c238cccac3a0 8e084a00_c96c_e3c3_28ca_b9b98cf2d546["HttpResponseStatus()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 8e084a00_c96c_e3c3_28ca_b9b98cf2d546 b444049b_e6ec_1bd4_9e2f_82f14ee95a4c["FullHttpResponse()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| b444049b_e6ec_1bd4_9e2f_82f14ee95a4c 18525c40_6dc4_1473_10b3_e63a9b6f606c["FullHttpRequest()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 18525c40_6dc4_1473_10b3_e63a9b6f606c 56b27877_2f95_3c63_5742_dc35487f1536["String()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 56b27877_2f95_3c63_5742_dc35487f1536 2127e801_d6bc_ab32_3626_26db5a92d227["HttpRequest()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 2127e801_d6bc_ab32_3626_26db5a92d227 83a0b8c3_93ae_5f1e_df15_907f321755f6["HttpResponse()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 83a0b8c3_93ae_5f1e_df15_907f321755f6 f883ee49_b387_2383_d1d6_1d09b3c40688["addHttp2ToHttpHeaders()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| f883ee49_b387_2383_d1d6_1d09b3c40688 e4140185_26f8_5319_cffa_a46eb5356b83["Http2Headers()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| e4140185_26f8_5319_cffa_a46eb5356b83 9ef85cd2_4d7c_e875_6493_f1c7033de54a["toLowercaseMap()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 9ef85cd2_4d7c_e875_6493_f1c7033de54a d788f36c_550b_912c_a38b_bccd9f57ab18["toHttp2HeadersFilterTE()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| d788f36c_550b_912c_a38b_bccd9f57ab18 6d71d73b_826f_80a2_d574_05df829c5c40["toHttp2Headers()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 6d71d73b_826f_80a2_d574_05df829c5c40 6dc1e856_6655_f72d_37e8_0d71045d347f["splitValidCookieHeader()"] 0560b510_c1dc_0a46_6dca_e5dbfb67d807 -->|method| 6dc1e856_6655_f72d_37e8_0d71045d347f
Relationship Graph
Source Code
codec-http2/src/main/java/io/netty/handler/codec/http2/HttpConversionUtil.java lines 70–735
public final class HttpConversionUtil {
/**
* The set of headers that should not be directly copied when converting headers from HTTP to HTTP/2.
*/
private static final CharSequenceMap<AsciiString> HTTP_TO_HTTP2_HEADER_BLACKLIST =
new CharSequenceMap<AsciiString>();
static {
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(CONNECTION, EMPTY_STRING);
@SuppressWarnings("deprecation")
AsciiString keepAlive = HttpHeaderNames.KEEP_ALIVE;
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(keepAlive, EMPTY_STRING);
@SuppressWarnings("deprecation")
AsciiString proxyConnection = HttpHeaderNames.PROXY_CONNECTION;
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(proxyConnection, EMPTY_STRING);
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(HttpHeaderNames.TRANSFER_ENCODING, EMPTY_STRING);
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(HttpHeaderNames.HOST, EMPTY_STRING);
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(HttpHeaderNames.UPGRADE, EMPTY_STRING);
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(ExtensionHeaderNames.STREAM_ID.text(), EMPTY_STRING);
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(ExtensionHeaderNames.SCHEME.text(), EMPTY_STRING);
HTTP_TO_HTTP2_HEADER_BLACKLIST.add(ExtensionHeaderNames.PATH.text(), EMPTY_STRING);
}
/**
* This will be the method used for {@link HttpRequest} objects generated out of the HTTP message flow defined in <a
* href="https://tools.ietf.org/html/rfc7540#section-8.1">[RFC 7540], Section 8.1</a>
*/
public static final HttpMethod OUT_OF_MESSAGE_SEQUENCE_METHOD = HttpMethod.OPTIONS;
/**
* This will be the path used for {@link HttpRequest} objects generated out of the HTTP message flow defined in <a
* href="https://tools.ietf.org/html/rfc7540#section-8.1">[RFC 7540], Section 8.1</a>
*/
public static final String OUT_OF_MESSAGE_SEQUENCE_PATH = "";
/**
* This will be the status code used for {@link HttpResponse} objects generated out of the HTTP message flow defined
* in <a href="https://tools.ietf.org/html/rfc7540#section-8.1">[RFC 7540], Section 8.1</a>
*/
public static final HttpResponseStatus OUT_OF_MESSAGE_SEQUENCE_RETURN_CODE = HttpResponseStatus.OK;
/**
* <a href="https://tools.ietf.org/html/rfc7540#section-8.1.2.3">[RFC 7540], 8.1.2.3</a> states the path must not
* be empty, and instead should be {@code /}.
*/
private static final AsciiString EMPTY_REQUEST_PATH = AsciiString.cached("/");
private HttpConversionUtil() {
}
/**
* Provides the HTTP header extensions used to carry HTTP/2 information in HTTP objects
*/
public enum ExtensionHeaderNames {
/**
* HTTP extension header which will identify the stream id from the HTTP/2 event(s) responsible for
* generating an {@code HttpObject}
* <p>
* {@code "x-http2-stream-id"}
*/
STREAM_ID("x-http2-stream-id"),
/**
* HTTP extension header which will identify the scheme pseudo header from the HTTP/2 event(s) responsible for
* generating an {@code HttpObject}
* <p>
* {@code "x-http2-scheme"}
*/
SCHEME("x-http2-scheme"),
/**
* HTTP extension header which will identify the path pseudo header from the HTTP/2 event(s) responsible for
* generating an {@code HttpObject}
* <p>
* {@code "x-http2-path"}
*/
PATH("x-http2-path"),
/**
* HTTP extension header which will identify the stream id used to create this stream in an HTTP/2 push promise
* frame
* <p>
* {@code "x-http2-stream-promise-id"}
*/
STREAM_PROMISE_ID("x-http2-stream-promise-id"),
Source
Frequently Asked Questions
What is the HttpConversionUtil class?
HttpConversionUtil is a class in the netty codebase, defined in codec-http2/src/main/java/io/netty/handler/codec/http2/HttpConversionUtil.java.
Where is HttpConversionUtil defined?
HttpConversionUtil is defined in codec-http2/src/main/java/io/netty/handler/codec/http2/HttpConversionUtil.java at line 70.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free