refactor: update health report to connection test and simplify proto definitions

This commit is contained in:
GW_MC
2026-05-31 02:36:30 +00:00
parent 7173f504ed
commit 9f72cd4bbb
3 changed files with 77 additions and 206 deletions

View File

@@ -62,14 +62,14 @@ async fn main() {
// send a dummy heartbeat to verify the connection is working
let client = master_connector.get_client();
let request = nxmesh_proto::HealthReport {
let request = nxmesh_proto::TestRequest {
..Default::default()
};
match client.lock().await.report_health(request).await {
Ok(_) => info!("Successfully sent health report to master."),
match client.lock().await.connection_test(request).await {
Ok(_) => info!("Successfully sent connection test to master."),
Err(e) => {
error!("Failed to send health report to master: {}", e);
error!("Failed to send connection test to master: {}", e);
exit(1);
}
}