http-request 23.3.0

http-request is a lightweight, efficient library for building, sending, and handling HTTP/HTTPS requests in Rust applications. It provides a simple and intuitive API, allowing developers to easily interact with web services, whether they use the "HTTP" or "HTTPS" protocol. The library supports various HTTP methods, custom headers, request bodies, timeout, automatic handling of redirects (including detecting redirect loops), and enhanced response body decoding (both automatic and manual), enabling fast and secure communication. Whether working with secure "HTTPS" connections or standard "HTTP" requests, the library is optimized for performance, minimal resource usage, and easy integration into Rust projects.
Documentation
/// Number of independent lock stripes in the HTTP/1.1 connection pool (must be a power of two <= 64).
pub(crate) const H1_POOL_STRIPES: usize = 16;

/// Maximum idle HTTP/1.1 connections cached per `(origin, proxy)` inside one pool stripe.
pub(crate) const POOL_MAX_IDLE_PER_STRIPE_HOST: usize = 16;

/// Maximum idle HTTP/1.1 connections cached per stripe across all origins (`16 * 64 = 1024` total).
pub(crate) const POOL_MAX_IDLE_PER_STRIPE: usize = 64;

/// Maximum total idle HTTP/2 senders retained across all origins.
pub(crate) const POOL_MAX_IDLE_TOTAL: usize = 1024;

/// Number of alternate stripes probed via `try_lock` before blocking on the preferred stripe.
pub(crate) const H1_POOL_PROBE_ATTEMPTS: usize = 4;

/// Idle keep-alive timeout before a pooled connection is discarded (seconds).
pub(crate) const POOL_IDLE_TTL_SECS: u64 = 60;

/// Maximum number of reusable byte buffers kept in each worker's thread-local pool.
pub(crate) const CLIENT_MAX_POOLED_BUFFERS: usize = 32;

/// Largest byte buffer capacity retained in the worker-local buffer pool.
pub(crate) const CLIENT_MAX_POOLED_BUFFER_CAP: usize = 64 * 1024;