Skip to main content

serve

Function serve 

Source
pub async fn serve(
    listener: TcpListener,
) -> Result<(SocketAddr, JoinHandle<()>)>
Expand description

Bind the facade on listener and serve it in the background. Returns the bound address (use :0 for an ephemeral port) and a handle that stops the server on abort.