From 3817ec811d76b91d3d4924003a4d48d0cd43a576 Mon Sep 17 00:00:00 2001 From: Melody Horn Date: Fri, 24 Dec 2021 16:25:51 -0700 Subject: rust is a myth. it doesn't exist --- src/utils.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/utils.rs') diff --git a/src/utils.rs b/src/utils.rs index 0bd5c2e..ebc21f2 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -1,2 +1,10 @@ +use async_trait::async_trait; +use hyper::{Body, Request, Response}; + pub mod proxy_child; pub mod serve_static; + +#[async_trait] +pub trait HttpHandler: Send + Sync { + async fn handle(&self, request: Request) -> Response; +} -- cgit v1.2.3