Function caesar_transfer_iu::__shuttle_axum
source · pub(crate) async fn __shuttle_axum() -> ShuttleAxumExpand description
The main function that sets up the Axum application.
This function creates a new server data structure and sets up the application routes. The routes include “/ws” for the websocket handler, “/upload” for the upload info handler, “/download/:name” for the download info handler, and “/download_success/:name” for the download success handler. The routes are associated with the corresponding handlers.
The application state is wrapped around the routes using the with_state method.
The client IP source is added as an extension using the layer method.
The function returns a ShuttleAxum result.