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

Handle websocket errors in KubeExec #1860

Closed
5 tasks
orenbm opened this issue Oct 4, 2020 · 0 comments
Closed
5 tasks

Handle websocket errors in KubeExec #1860

orenbm opened this issue Oct 4, 2020 · 0 comments

Comments

@orenbm
Copy link
Member

orenbm commented Oct 4, 2020

The KubeExec class doesn't verify that there were no errors in the stream and returns the messages to
the caller. Then, the caller (in this case 'InjectClientCert') parses the messages and verifies that there were no errors.

It is better to handle the errors in the KubeExec class and raise an error if one occurred.

DoD:

  • The KubeExec class raises an error in case one occurred
  • The KubeExec class is aligned to the CommandClass pattern
    • Rename class to the action it performs
    • Use dependencies so we can easily mock them
    • call function tells the class's story
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants