Bound in-process queues with Channel<T>
Limit buffered work with a bounded channel, then decide whether producers should wait, reject, or drop work when it fills.
Limit buffered work with a bounded channel, then decide whether producers should wait, reject, or drop work when it fills.
Keep span work between awaits. Carry memory or its backing buffer through asynchronous I/O.
A CancellationToken in scope does nothing unless the async enumeration receives and observes it.
Use async to avoid blocking while I/O is in flight, and treat CPU parallelism as a separate measured design decision.
Prefer Task unless you have a measured allocation reason and a simple consumption contract.
If work can fail, give it ownership, logging, cancellation, and a lifecycle.
Create unrelated asynchronous operations first, then await them together.