Function kvarn::source ·
pub async fn handle_connection( stream: TcpStream, address: SocketAddr, descriptor: Arc<PortDescriptor>, continue_accepting: impl FnMut() -> bool ) -> Result<()>
Handles a single connection. This includes encrypting it, extracting the HTTP header information,
optionally (HTTP/2 & HTTP/3) decompressing them, and passing the request to
It will also recognize which host should handle the connection.
Here, both layer 2 and layer 3 are handled.
Will pass any errors from reading the request, making a TLS handshake, and writing the response.
handle_request(); errors from them are passed up, through this fn.