5 releases (3 breaking)

new 0.4.0 Nov 1, 2024
0.3.0 Jul 12, 2024
0.2.0 May 10, 2024
0.1.1 Apr 18, 2024
0.1.0 Feb 28, 2024

#1948 in Network programming

Download history 898/week @ 2024-07-12 595/week @ 2024-07-19 732/week @ 2024-07-26 776/week @ 2024-08-02 724/week @ 2024-08-09 959/week @ 2024-08-16 944/week @ 2024-08-23 811/week @ 2024-08-30 702/week @ 2024-09-06 636/week @ 2024-09-13 4924/week @ 2024-09-20 6734/week @ 2024-09-27 4819/week @ 2024-10-04 5936/week @ 2024-10-11 4944/week @ 2024-10-18 8561/week @ 2024-10-25

25,186 downloads per month
Used in 15 crates (10 directly)

Apache-2.0

1.5MB
26K SLoC

pingora-proxy

Programmable HTTP proxy built on top of [pingora_core].

Features

  • HTTP/1.x and HTTP/2 for both downstream and upstream
  • Connection pooling
  • TLSv1.3, mutual TLS, customizable CA
  • Request/Response scanning, modification or rejection
  • Dynamic upstream selection
  • Configurable retry and failover
  • Fully programmable and customizable at any stage of a HTTP request

How to use

Users of this crate defines their proxy by implementing [ProxyHttp] trait, which contains the callbacks to be invoked at each stage of a HTTP request.

Then the service can be passed into [http_proxy_service()] for a pingora_core::server::Server to run it.

See examples/load_balancer.rs for a detailed example.

Dependencies

~28–53MB
~1M SLoC