3 ms·
We have something very similar to this that we wrote at my work. Ours is based off Twisted, which works pretty similarly to the new async stuff in python3. Th
by war1025 6y ago
We have something very similar to this that we wrote at my work.
Ours is based off Twisted, which works pretty similarly to the new async stuff in python3.
The thing ours does, that I can't tell if this one supports or not, is you pass it a list of functions you want it to call (in python3 you would just pass it coroutines I suppose, but in Twisted an async function gets scheduled automatically, so you need to pass it in an uncalled state), and then you specify the "width" of the pipeline, and it runs through your list of calls, ensuring that "width" number of calls are in flight at a time.
It's a super useful little utility to have around.