-
Notifications
You must be signed in to change notification settings - Fork 31
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
Inefficient token management #34
Comments
Currently there is nothing built into this library to cache/refresh tokens. If you need this functionality the best way to achieve it is to write a function that returns a token, and then use the The way we are currently using this library is to generate a token for every single request, which I know is messy, but unfortunately other priorities have prevented me from improving this. To answer your other question, it is possible to set up a service account and use that for authentication. I'd be happy to provide more support after the long weekend if you need it. |
Thank you for your quick response. I have been unable to find a way to call the admin-api with a Service Account. |
I'm not sure if this is the 100% correct way to do it, but this is the procedure we follow: In the From the You can then use the Once you've got that part working you can change over to the If you manage to get this working it would be a welcome contribution to the library, unfortunately other priorities have prevented me from being able to work on such an implementation, which is why it is not already there. |
Hi,
It doesn't look nice to request a token for every operation.
Even if we get a new token when it expires, the same problem persists across multiple instance.
I tried with ServiceAccount + BasicAuth but couldn't succeed. I'm not sure if it's supported.
What do you think about this? Is there another way?
Thank you.
The text was updated successfully, but these errors were encountered: