pub fn spawn_stream_handler<P, F, Fut>(f: F) -> Result<P, Error>
where P: Proxy, F: FnMut(Request<P::Protocol>) -> Fut + 'static + Send, Fut: Future<Output = ()> + 'static + Send,
Expand description

Utility that spawns a new task to handle requests of a particular type. The request handler must be threadsafe. The requests are handled one at a time.