Make use of AuthorizationProvider (and cache clients?) #382
Open
Description
github-api supports self-refreshing authorization providers, as evidenced by org.kohsuke.github.extras.authorization.JWTTokenProvider
and org.kohsuke.github.authorization.OrgAppInstallationAuthorizationProvider
.
We don't need to use these implementations if they're not a good fit, but we could use our own implementations of org.kohsuke.github.authorization.AuthorizationProvider
in order to create a client that refreshes its token automatically.
The main advantage would be that a given client could stay valid forever (because it automatically refreshes its token if necessary before each HTTP request), opening the door to caching clients (potentially forever, in the case of the application client).
Metadata
Assignees
Labels
No labels