Closed infinityzero closed 8 years ago
Hi. You are getting this exception because retrieveTokens
returns null
and then null.getRefreshToken()
is called. There are no tokens. Is a user signed in?
This issue seems similar to https://github.com/telenordigital/connect-ios-sdk/issues/19. Are you also using some sort of middle-ware server?
Yes, I'm using middle-ware server to verify connect access token.
Yes, user already signed in.
How do you currently keep track of when the accessToken
expires, and when to update the tokens?
I see now that the SDK does not have the functionality to keep track of this. I could also make it so that the SDK did this for you. Is this functionality wanted?
I'm not keep track of access token in Android. Update the token when received session expire from our middle-ware server.
Please see the below flow:
ConnectSdk.getAccessToken()
.ConnectSdk.updateTokens(...)
If SDK have the functionality to keep track of access token, that would be great.
Great. Working on it #33. You will be able to call getValidAccessToken(…)
.
After the pull request is merged I will have to later release a new version of the SDK, after some testing, then you can use it.
The newest release now has this feature: https://github.com/telenordigital/connect-android-sdk/releases
When I call below method:
Got below exception: