Skip to main content

Module config

Module config 

Source
Expand description

HTTP routing and server bootstrap.

Re-exports ConfigurationRegistrant, which owns the shared Router, mounts RouteControllers, and starts the Hyper HTTP server. Use this module when wiring routes manually without GenericStartup.

let registrant = std::sync::Arc::new(ConfigurationRegistrant::new(addr));
registrant.mount_controller(controller).await;
registrant.serve().await?;

Re-exports§

pub use crate::controller::ConfigurationRegistrant;