Hey all,
I’m trying to implement the okhttp Authenticator to re-authenticate upon access token expiration (401).
My question is how to handle when multiple networks calls are sent and return with 401.
I tried to annotate the function with @Syncrornized in order to call the remote refresh token API only once instead of for each of the bounced 401 calls.
the annotation doesn’t work and i see in the logs that the function that is annotated with it still being called more than once at given time.
any suggestion/help?