4 ms·
Two separate threads run in parallel, but one thread cannot do two subtasks in parallel without submitting parallel jobs to an executor or a StructuredTaskScope
by mgraczyk 4y ago
Two separate threads run in parallel, but one thread cannot do two subtasks in parallel without submitting parallel jobs to an executor or a StructuredTaskScope subtask manager. It's basically forcing the developer to do all the hard work and boilerplate that async/await saves you.
- pron 4y ago> It's basically forcing the developer to do all the hard work and boilerplate that async/await saves you. It doesn't. Both require the exact same kind of invocation by the user. Neither automatically parallelises operations that aren't explicitly marked for parallelisation.