Use can also use Coroutines with lifecycleScope
to lunch network call in background thread
In Activity the best way to call retrieveInfo()
inside onCreate
or OnResume
method
// Call suspend function safely here inside coroutine scope
lifecycleScope.launch{
val info = retriveInfo()
}