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

Don't deprovision provisioned host due to error #916

Merged
merged 1 commit into from
Jun 15, 2021

Conversation

zaneb
Copy link
Member

@zaneb zaneb commented Jun 15, 2021

During provisioning, we want an error to cause the Host to be
deprovisioned again, but we very much do not want that to happen when
the Host is already provisioned. Due to an error in
0a7713b, provisioned Hosts were being
automatically deprovisioned whenever an error (other than a registration
error) occurred.

In practice this only manifested on Adopt() failures, since we don't yet
report power management failures.

Fixes #915

@metal3-io-bot metal3-io-bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Jun 15, 2021
@hardys hardys requested review from andfasano and dhellmann June 15, 2021 18:27
@hardys
Copy link
Member

hardys commented Jun 15, 2021

/approve

@metal3-io-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hardys

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@metal3-io-bot metal3-io-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 15, 2021
@hardys
Copy link
Member

hardys commented Jun 15, 2021

Adding a test to cover this would be good, but otherwise lgtm, thanks!

During provisioning, we want an error to cause the Host to be
deprovisioned again, but we very much do not want that to happen when
the Host is already provisioned. Due to an error in
0a7713b, provisioned Hosts were being
automatically deprovisioned whenever an error (other than a registration
error) occurred.

In practice this only manifested on Adopt() failures, since we don't yet
report power management failures.

Fixes metal3-io#915
@zaneb zaneb force-pushed the provisioning-cancel-error branch from 318850a to c15f0d8 Compare June 15, 2021 18:32
@metal3-io-bot metal3-io-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 15, 2021
@zaneb zaneb requested a review from stbenjam June 15, 2021 18:33
@zaneb
Copy link
Member Author

zaneb commented Jun 15, 2021

Added a test.
/test-integration

@sadasu
Copy link
Member

sadasu commented Jun 15, 2021

/lgtm

@metal3-io-bot
Copy link
Contributor

@sadasu: adding LGTM is restricted to approvers and reviewers in OWNERS files.

In response to this:

/lgtm

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@stbenjam
Copy link
Member

/lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Adoption errors cause deprovisioning
5 participants