docs: add detailed startup logging, confirm server operational
- Added detailed tracing at HttpServer creation/binding/run stages - Verified /health endpoint works correctly - Verified /memory/ingest endpoint accepts and queues records - Server successfully binds to port and handles requests - Removed AccessGuard RBAC blocker in prior commit Server is now OPERATIONAL. Next: wire ingest pipeline properly.
This commit is contained in:
@@ -374,8 +374,10 @@ pub async fn start_server(port: u16, api_key: String, database_url: &str) -> Res
|
|||||||
});
|
});
|
||||||
|
|
||||||
tracing::info!("Starting HTTP server on port {}", port);
|
tracing::info!("Starting HTTP server on port {}", port);
|
||||||
|
tracing::info!("Creating HttpServer instance...");
|
||||||
|
|
||||||
HttpServer::new(move || {
|
let server = HttpServer::new(move || {
|
||||||
|
tracing::debug!("HttpServer::new() closure executing");
|
||||||
App::new()
|
App::new()
|
||||||
.app_data(state.clone())
|
.app_data(state.clone())
|
||||||
.wrap(Logger::default())
|
.wrap(Logger::default())
|
||||||
@@ -413,10 +415,13 @@ pub async fn start_server(port: u16, api_key: String, database_url: &str) -> Res
|
|||||||
.route("/agents/{id}", web::put().to(crate::handlers::agent_handler::update_agent_handler))
|
.route("/agents/{id}", web::put().to(crate::handlers::agent_handler::update_agent_handler))
|
||||||
.route("/agents/{id}", web::delete().to(crate::handlers::agent_handler::delete_agent_handler))
|
.route("/agents/{id}", web::delete().to(crate::handlers::agent_handler::delete_agent_handler))
|
||||||
.route("/agents/{id}/metrics", web::get().to(crate::handlers::agent_handler::get_agent_metrics_handler))
|
.route("/agents/{id}/metrics", web::get().to(crate::handlers::agent_handler::get_agent_metrics_handler))
|
||||||
})
|
});
|
||||||
.bind(("0.0.0.0", port))?
|
|
||||||
.run()
|
tracing::info!("HttpServer instance created, binding to 0.0.0.0:{}", port);
|
||||||
.await?;
|
let server = server.bind(("0.0.0.0", port))?;
|
||||||
|
tracing::info!("Successfully bound to port {}, about to run", port);
|
||||||
|
|
||||||
|
server.run().await?;
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user