Increase channel capacity

This commit is contained in:
Tony Klink 2024-02-19 10:47:49 -06:00
parent d06206bb24
commit b6dcf61995
Signed by: klink
GPG key ID: 85175567C4D19231

View file

@ -112,7 +112,7 @@ impl PubSub {
}
pub async fn subscribe(&self, topic: &str) -> broadcast::Receiver<Message> {
let (tx, _rx) = broadcast::channel(256); // 256 is the channel capacity
let (tx, _rx) = broadcast::channel(20_000); // 20000 is the channel capacity
let mut subscribers = self.subscribers.lock().await;
subscribers
.entry(topic.to_string())