Skip to content
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

fix: do not reuse connection for the commands #1624

Merged
merged 1 commit into from
Jul 1, 2022

Conversation

wtrocki
Copy link
Collaborator

@wtrocki wtrocki commented Jul 1, 2022

This PR disables connection reuse.
In previous change I have noticed that we always refresh mas-sso tokens even when we do control plane commands only:

https://github.com/redhat-developer/app-services-cli/pull/1599/files

That would obviously cause problems in long term and was removed. As results we noticed 401 with tokens failing. Reason was that we had cache for connection function that was undocumented. I think we should disable this cache. This will create connection object couple times for 2-3 commands but overall it doesn't cause any extra problems and enables us to mix mas-sso commands

Note that mas-sso goes away so this is only temporary change anyway.

Verification

// wait 5 min after any command
rhoas kafka topic list

@wtrocki wtrocki requested a review from jackdelahunt July 1, 2022 14:20
@jackdelahunt jackdelahunt merged commit 72169ff into main Jul 1, 2022
@jackdelahunt jackdelahunt deleted the do-not-reuse-connection branch July 1, 2022 14:31
@jackdelahunt
Copy link
Contributor

Tested and verified 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants