Runtime diagnostics for leaked messages in unbounded channels (#12971)

This commit is contained in:
Dmitry Markin
2022-12-23 16:03:08 +03:00
committed by GitHub
parent 70e9f8e920
commit 34eb463d99
37 changed files with 257 additions and 134 deletions
+2 -2
View File
@@ -79,8 +79,8 @@ impl<Payload, TK: TracingKeyStr> NotificationStream<Payload, TK> {
}
/// Subscribe to a channel through which the generic payload can be received.
pub fn subscribe(&self) -> NotificationReceiver<Payload> {
let receiver = self.hub.subscribe(());
pub fn subscribe(&self, queue_size_warning: i64) -> NotificationReceiver<Payload> {
let receiver = self.hub.subscribe((), queue_size_warning);
NotificationReceiver { receiver }
}
}