http-type 23.2.0

A comprehensive Rust type library for HTTP operations and concurrent programming. Provides core HTTP types (Request/Response with builder patterns, Method, HttpStatus, HttpVersion, ContentType, FileExtension with MIME mapping, Cookie parsing/building, HttpUrl parsing, WebSocket frame/opcode, protocol upgrade types, stream/task management, panic handling), thread-safe concurrent wrappers (ArcMutex, ArcRwLock, BoxRwLock, RcRwLock), dynamic dispatch types (BoxAny, RcAny, ArcAny with Send/Sync variants), high-performance hash collections (HashMapXxHash3_64, HashSetXxHash3_64), and static lifetime utilities (BoxLeak, Lifetime trait).
Documentation
use super::*;

/// Byte delimiting a quoted HTTP field member.
pub(crate) const HTTP_QUOTED_FIELD_QUOTE: u8 = b'"';

/// Byte escaping the next character inside a quoted HTTP field member.
pub(crate) const HTTP_QUOTED_FIELD_ESCAPE: u8 = b'\\';

/// The diagnostic for a WebSocket read attempted before parser initialization.
pub(crate) const WEBSOCKET_STATE_ERROR: &str = "WebSocket state must be initialized";

/// The diagnostic for a WebSocket read whose unread buffer exceeds the configured limit.
pub(crate) const WEBSOCKET_FRAME_TOO_LARGE_ERROR: &str = "WebSocket frame exceeds max body size";

/// The complete HTTP/1.1 interim response with no fields or body.
pub(super) const HTTP_CONTINUE_RESPONSE: &[u8] = b"HTTP/1.1 100 Continue\r\n\r\n";

/// The maximum number of reusable header and query entries retained per worker.
pub(crate) const MAX_POOLED_HEADER_ENTRIES: usize = B_128;

/// The maximum retained capacity of a reusable header or query string.
pub(crate) const MAX_POOLED_HEADER_STRING_CAPACITY: usize = 4 * 1024;

/// The maximum retained capacity of a reusable repeated-value list.
pub(crate) const MAX_POOLED_HEADER_VALUE_CAPACITY: usize = B_4;

/// Size of the stack-allocated read buffer used by the zero-pool HTTP/1.1 fast path.
pub(crate) const STACK_READ_BUF_SIZE: usize = DEFAULT_BUFFER_SIZE;

/// Number of staggered phase buckets in the shared WebSocket idle heartbeat wheel.
pub(crate) const WS_HEARTBEAT_BUCKETS: usize = 16;

/// Minimum adjusted WebSocket read-timeout interval in milliseconds routed to the shared heartbeat wheel.
pub(crate) const WS_HEARTBEAT_MIN_WHEEL_MS: u64 = 1_000;

/// Microseconds per millisecond for exact multi-bucket WebSocket heartbeat stepping.
pub(crate) const WS_MICROS_PER_MS: u64 = 1_000;

/// Minimum step duration in microseconds for a shared WebSocket heartbeat wheel.
pub(crate) const WS_HEARTBEAT_MIN_STEP_MICROS: u64 = 1_000;

/// First wire byte of an RFC 6455 unmasked server Pong control frame (`FIN=1, opcode=0xA`).
pub(crate) const WS_PONG_FIRST_BYTE: u8 = 0x8A;

/// Maximum bytes in a stack-encoded RFC 6455 Pong control frame (`2` header + `125` max control payload).
pub(crate) const WS_PONG_STACK_CAP: usize = 127;

/// Maximum RFC 6455 frame header overhead in bytes (`2` base + `8` ext64 + `4` mask).
pub(crate) const WS_MAX_FRAME_HEADER_BYTES: usize = 14;

/// Minimum standard RFC 6455 close code range (`1000..=1003`).
pub(crate) const WS_CLOSE_STD_RANGE_1_START: u16 = 1000;

/// Maximum of the first standard RFC 6455 close code range (`1000..=1003`).
pub(crate) const WS_CLOSE_STD_RANGE_1_END: u16 = 1003;

/// Minimum of the second standard RFC 6455 close code range (`1007..=1011`).
pub(crate) const WS_CLOSE_STD_RANGE_2_START: u16 = 1007;

/// Maximum of the second standard RFC 6455 close code range (`1007..=1011`).
pub(crate) const WS_CLOSE_STD_RANGE_2_END: u16 = 1011;

/// Minimum application-defined RFC 6455 close code (`3000..=4999`).
pub(crate) const WS_CLOSE_APP_RANGE_START: u16 = 3000;

/// Maximum application-defined RFC 6455 close code (`3000..=4999`).
pub(crate) const WS_CLOSE_APP_RANGE_END: u16 = 4999;