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

Gracefully handle BMCs returning "Insufficient resources" #30

Open
gebn opened this issue Sep 22, 2019 · 1 comment
Open

Gracefully handle BMCs returning "Insufficient resources" #30

gebn opened this issue Sep 22, 2019 · 1 comment
Labels
bug Something isn't working
Milestone

Comments

@gebn
Copy link
Owner

gebn commented Sep 22, 2019

if err := bmc.ValidateResponse(c.session.SendCommand(cmdFirstCtx, cmd)); err != nil {

If we decode the command response successfully, we don't need to tear down the session, even if the completion code is non-normal, as the session is still in a good state. We will want to retry in the case of insufficient resources, otherwise return the error up, as we can't move past it. Doing this will invalidate this comment:

// we don't continue on error, as the only reason for an error is ctx

Perhaps modify that function to keep returning early iff the context has expired.

@gebn
Copy link
Owner Author

gebn commented Oct 7, 2019

Test this - overwhelm a BMC such that it returns a non-normal completion code.

@gebn gebn added the bug Something isn't working label Oct 9, 2019
@gebn gebn added this to the Stable milestone Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant