Threading issue in WebAuthenticationClient


As Kotlin Coroutines are used extensively throughout the SDKs. Can I assume there would be no multiple threading issues? I think there would NO that kinda issue, just wanna confirm here.


Hi @DanTech! Just to confirm, are you asking if it is safe to call login, refresh, and logout concurrently in the SDK?

yes, correct. that is the question! Any thought?

Hi @DanTech, I ran this by our Kotlin SDK team and they don’t recommend it i.e. don’t think it is safe. The WebAuthenticationClient in Kotlin SDK only provides login and logout functions and they are wondering in what scenario calling both of them would be valid.

Thanks for the reply. Will there be a mutlithreading issue if the login func is called multiple times? e.g. the 1st login call is not returned yet but the 2nd login call was initiated.

I’ll ask our team and get back to you.

Thanks Sigama. Is there any update for us?

Hi @DanTech thank you for your patience. I confirmed the 1st login call would never return in that case.

1 Like