https://kotlinlang.org logo
#coroutines
Title
# coroutines
n

Norbi

06/21/2022, 7:12 AM
Is it OK to call
runBlocking()
on each HTTP request? Does it degrade performance a lot? Thanks.
i

Ilya

06/21/2022, 8:07 AM
As I remember it's recommended to use
runBlicking()
only for tests
y

yschimke

06/21/2022, 8:22 AM
Tests and bridging blocking APIs to coroutines.
It is designed to bridge regular blocking code to libraries that are written in suspending style, to be used in
main
functions and in tests.
👍 1
n

Norbi

06/21/2022, 3:36 PM
Thanks. And is it OK to call
runBlocking()
on each HTTP request? Does it degrade performance a lot?
6 Views