pub fn register_route<State, E>( method: &'static str, path: &'static str, handler: impl Fn(RouteContext<State, E>) -> Pin<Box<dyn Future<Output = Result<Value, Box<dyn Error + Sync + Send>>> + Send>> + Send + Sync + 'static, )where E: RoutableHttpEvent, State: Send + Sync + Clone + 'static,