kingsley
09/17/2017, 12:41 PMJob
is lightweight and it’s more like the representation of the state of the coroutine. Deferred
itself is actually a Job
, but with more capability. It holds the result of the execution
2. The behavior of async
and launch
is slightly different in that launch
will propagate any exceptions thrown, whereas async
saves that result/exception in the Deferred
. This also makes sense given the description in (1) above.
This is only my understanding of it. Perhaps someone will put up a more detailed description of the design decisions.