Expand description
Server bootstrap for the Tako framework.
Hosts every concrete listener implementation (HTTP/1, TLS, HTTP/3, raw TCP,
UDP, Unix sockets, plus the compio variants) and the PROXY protocol parser.
Re-exported under the original tako::* paths via the umbrella crate.
Re-exports§
pub use server_compio::serve;compiopub use server_compio::serve_with_config;compiopub use server_compio::serve_with_shutdown;compiopub use server_compio::serve_with_shutdown_and_config;compiopub use server_tls_compio::serve_tls;compio-tlspub use server_tls_compio::serve_tls_with_config;compio-tlspub use server_tls_compio::serve_tls_with_shutdown;compio-tlspub use server_tls_compio::serve_tls_with_shutdown_and_config;compio-tls
Modules§
- server_
compio compio - server_
tcp - Raw TCP server for handling arbitrary TCP connections. Raw TCP server for handling arbitrary TCP connections.
- server_
tls_ compio compio-tlsandtls - TLS-enabled HTTP server implementation for secure connections (compio runtime).
- server_
udp - UDP datagram server for handling raw UDP packets. UDP datagram server for handling raw UDP packets.
- socket_
activation socket-activation - systemd / s6 / catflap socket activation helpers (LISTEN_FDS). systemd / s6 / catflap socket activation.
Structs§
- Accept
Backoff - Exponential backoff state for
listener.accept()retry loops. - Compio
Server compio - Compio-runtime server entry point. Construct with
CompioServer::builder. - Compio
Server Builder compio - Fluent constructor for the compio-runtime
CompioServer. - Reloadable
Resolver tls - A
ResolvesServerCertwhose backingrustls::sign::CertifiedKeycan be swapped at runtime viaReloadableResolver::reload_from_pem. - Server
Config - Production-readiness knobs shared by every Tako server transport.
- Server
Handle - Background-task handle returned by every
spawn_*method.
Enums§
- Client
Auth tls - Client-authentication policy applied to a TLS server.
- H3Congestion
- Selectable QUIC congestion controller. Mirrors the controllers shipped by
quinn::congestion. Exposed here so HTTP/3 deployments can pick a profile without depending on quinn directly from the application crate. - TlsCert
- Optional TLS material the builder can attach to a TLS-mode server.
Functions§
- bind_
with_ port_ fallback compio - Bind a TCP listener for
addr, asking interactively to increment the port if it is already in use (compio version). - build_
rustls_ server_ config tls - Build an
Arc<rustls::ServerConfig>from aTlsCertand the desired ALPN protocol list. - either
- Convenience: await
signal_aorsignal_b, whichever fires first.