Use tokio::sync::Semaphore
to wait for available task slots
#388
Labels
enhancement
New feature or request
tokio::sync::Semaphore
to wait for available task slots
#388
Is your feature request related to a problem or challenge? Please describe what you are trying to do.
@Dandandan, I think we could improve on #378 by using
tokio::sync::Semaphore
to wait for task slots to open up, rather than sleep spinning. It could look something like this:Looking at the current implementation, its pretty much the same thing as what a tokio semaphore does, except with the sleeping spin loop.
Describe alternatives you've considered
Just a thought, implementing this isn't a deal breaker
The text was updated successfully, but these errors were encountered: