This'd be useful to get a simple head count of a task "pool": if send() times out, you could check the receiver_count() to see if it's worth spawning another worker thread. A concern is that maybe it'd be exposing implementation details, but I feel like the senders/receivers are always gonna be reference counted to some extent so it's not hard to provide.
This'd be useful to get a simple head count of a task "pool": if
send()
times out, you could check thereceiver_count()
to see if it's worth spawning another worker thread. A concern is that maybe it'd be exposing implementation details, but I feel like the senders/receivers are always gonna be reference counted to some extent so it's not hard to provide.