Crate easy_http_proxy_server

Crate easy_http_proxy_server 

Source
Expand description

A simple HTTP forward proxy server library built with Tokio

This library provides a lightweight HTTP/HTTPS proxy server implementation with connection pooling support for improved performance.

§Examples

use easy_http_proxy_server::{ProxyServer, ProxyConfig};
use std::net::SocketAddr;

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
    let config = ProxyConfig {
        addr: "127.0.0.1:3128".parse()?,
        verbose: true,
    };
     
    let server = ProxyServer::new(config);
    server.run().await?;
    Ok(())
}

Structs§

ConnectionPool
Connection pool for managing reusable TCP connections
ProxyConfig
Configuration for the proxy server
ProxyServer
HTTP/HTTPS proxy server

Enums§

ProxyError
Error type for the HTTP proxy library

Type Aliases§

Result