-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🌱 Add auth token refresh to Binding (#592)
There is an issue with long-time running tests e.g. for analysis on Konveyor with enabled Auth feature. Keycloak allows to refresh auth token, however the token for refresh was not stored in `binding.Client` and `binding.RichClient.Login` method didn't return the Login struct with Refresh and Expiry fields. Main changes in this PR - binding.client keeps api.Login struct instead of string token to allow use Refresh token to get a new one - binding.client.send method can catch 401 and try refresh auth token after each API call For visibility @mguetta1 Fixes konveyor/go-konveyor-tests#71 --------- Signed-off-by: Marek Aufart <[email protected]> Signed-off-by: Marek Aufart <[email protected]>
- Loading branch information
Showing
4 changed files
with
39 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters