Expand description
Shared HTTP mechanics for the built-in disaggregated-serving proxies.
Proxy-specific protocol bodies remain in their owning modules.
Structs§
- Proxy
Error Response - Proxy
Healthcheck Response - Healthcheck response body shared by the proxies.
- Proxy
Http Error - Error type shared by both proxies, carrying an HTTP status and a message.
- Proxy
Meta - Identity of a built-in proxy. Each proxy module owns its own
ProxyMetaso the proxy crate is the authority for the id/version recorded inBuiltinProxyevidence.
Functions§
- forward_
response - Forward an upstream response body verbatim, preserving status and content-type.
- join_
path - Join a base URL with a path, normalizing a single trailing slash on the base.
- outbound_
authorization - Resolve the outbound
Authorizationheader from the inbound request or theOPENAI_API_KEYenvironment variable. - run
- Build a multi-threaded Tokio runtime and drive
run_asyncto completion. - status_
code - Convert a
reqweststatus code into anaxum/httpstatus code. - upstream_
status_ error - Convert an unsuccessful upstream response into a
502 Bad GatewayProxyHttpErrorthat captures the upstream status and body.