-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lazily get token for clients #63
Comments
Can't speak to the java lib, but for the JS lib, I can assure you it doesn't, not sure why you and Srushtika are convinced otherwise. The client lib constructor does nothing that triggers getting an auth token, it's all done the first time something (a rest request or a connect()) calls getAuthParams() or getAuthHeaders(). I've just tried it as a sanity check; it really doesn't. |
Because that is what @paddybyers told me, and he wrote both the libs initially 😄
Great, that's what it should do. So this is perhaps just a Java issue if Java doesn't do this @paddybyers? Is it worth clarifying in the spec given most of the libs probably behave as they should then? |
In fact the java library does it lazily as well.
There's nothing in the spec that says explicitly one way or the other. I think it is probably worth clarifying. |
@mattheworiordan is this still something we're wanting to clarify in the spec? |
➤ Automation for Jira commented: The link to the corresponding Jira issue is https://ably.atlassian.net/browse/SDK-2808 |
It seems that the Java and JS libs obtain tokens automatically if token authentication is required for the client (
authUrl
specified for example), even ifautoConnect
is false.I think this is wrong. Why obtain a token until it's needed?
┆Issue is synchronized with this Jira Task by Unito
The text was updated successfully, but these errors were encountered: