Interview frequency: …
Short answer
Create or start the needed Futures and then pass them to Future.wait to collect the results, setting an error policy and not running operations that depend on a prior order.
Explanation
Future.wait waits on existing Futures and does not start work itself; use it when there is no dependency between requests, then handle the first error and the resources that have already started. Do not use it to parallelize CPU-bound work; Future scheduling does not create a new isolate.
Common mistakes
- Running operations that depend on a previous result inside Future.wait.
- Treating a Future.wait failure as an automatic cancellation of all other operations.