January 2019
Intermediate to advanced
520 pages
14h 32m
English
The first approach is to use the block_on or block_on_stream functions of the executor module. Both functions block the current thread to wait for the result. It is a naive approach that is not very flexible, but it is great in the following circumstances:
You should remember that you must not call this function in asynchronous code, because the call will block the executor and your program will stop working.
Read now
Unlock full access