From 2463986e8d6ab36792f6016d6852482ba4a71ced Mon Sep 17 00:00:00 2001 From: husky Date: Fri, 14 Mar 2025 18:49:27 -0700 Subject: [PATCH] await ack --- vorebot/src/main.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/vorebot/src/main.rs b/vorebot/src/main.rs index 789ebd6..7661dbd 100644 --- a/vorebot/src/main.rs +++ b/vorebot/src/main.rs @@ -99,10 +99,12 @@ async fn main() { let damping = args.get(2).map(|v| v.parse::().expect("BAD FP")).unwrap_or(0.45); warn!("suggesting {} with damping {}", suggestion_site, damping); - nats.publish(VOREBOT_SUGGESTED_SERVICE.to_string(), rmp_serde::to_vec(&CrawlRequest { + let ack = nats.publish(VOREBOT_SUGGESTED_SERVICE.to_string(), rmp_serde::to_vec(&CrawlRequest { url: suggestion_site.to_string(), damping, }).unwrap().into()).await.unwrap(); + + ack.await.expect("FATAL ERROR"); return; }