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

MGMT-19192: Add current stage when restoring host by Agent #7026

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

CrystalChun
Copy link
Contributor

For completeness, if a host has begun installing, store the current stage in the Agent's annotations so that if a host needs to be restored, we'll also have that data.

List all the issues related to this PR

  • New Feature
  • Enhancement
  • Bug fix
  • Tests
  • Documentation
  • CI/CD

What environments does this code impact?

  • Automation (CI, tools, etc)
  • Cloud
  • Operator Managed Deployments
  • None

How was this code tested?

  • assisted-test-infra environment
  • dev-scripts environment
  • Reviewer's test appreciated
  • Waiting for CI to do a full test run
  • Manual (Elaborate on how it was tested):
    • Installed a hypershift HostedCluster and scaled up the NodePool to include one Agent
    • wait until the Agent was in Done stage
    • Saved the Agent CR and deleted the Agent (ensuring to annotate before deleting with oc annotate agent --all -n spoke-cluster agent.agent-install.openshift.io/skip-spoke-cleanup=true)
    • Removed the host from the DB and restored the Agent (oc apply)
    • After the Agent is restored, checked oc get agent to verify that the stage was Done
  • No tests needed

Checklist

  • Title and description added to both, commit and PR.
  • Relevant issues have been associated (see CONTRIBUTING guide)
  • This change does not require a documentation update (docstring, docs, README, etc)
  • Does this change include unit-tests (note that code changes require unit-tests)

Reviewers Checklist

  • Are the title and description (in both PR and commit) meaningful and clear?
  • Is there a bug required (and linked) for this change?
  • Should this PR be backported?

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Nov 25, 2024
@openshift-ci-robot
Copy link

openshift-ci-robot commented Nov 25, 2024

@CrystalChun: This pull request references MGMT-19192 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.19.0" version, but no target version was set.

In response to this:

For completeness, if a host has begun installing, store the current stage in the Agent's annotations so that if a host needs to be restored, we'll also have that data.

List all the issues related to this PR

  • New Feature
  • Enhancement
  • Bug fix
  • Tests
  • Documentation
  • CI/CD

What environments does this code impact?

  • Automation (CI, tools, etc)
  • Cloud
  • Operator Managed Deployments
  • None

How was this code tested?

  • assisted-test-infra environment
  • dev-scripts environment
  • Reviewer's test appreciated
  • Waiting for CI to do a full test run
  • Manual (Elaborate on how it was tested):
    • Installed a hypershift HostedCluster and scaled up the NodePool to include one Agent
    • wait until the Agent was in Done stage
    • Saved the Agent CR and deleted the Agent (ensuring to annotate before deleting with oc annotate agent --all -n spoke-cluster agent.agent-install.openshift.io/skip-spoke-cleanup=true)
    • Removed the host from the DB and restored the Agent (oc apply)
    • After the Agent is restored, checked oc get agent to verify that the stage was Done
  • No tests needed

Checklist

  • Title and description added to both, commit and PR.
  • Relevant issues have been associated (see CONTRIBUTING guide)
  • This change does not require a documentation update (docstring, docs, README, etc)
  • Does this change include unit-tests (note that code changes require unit-tests)

Reviewers Checklist

  • Are the title and description (in both PR and commit) meaningful and clear?
  • Is there a bug required (and linked) for this change?
  • Should this PR be backported?

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Nov 25, 2024
Copy link

openshift-ci bot commented Nov 25, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@openshift-ci openshift-ci bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Nov 25, 2024
Copy link

openshift-ci bot commented Nov 25, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: CrystalChun

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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 25, 2024
For completeness, if a host has begun installing, store the
current stage in the Agent's annotations so that if a host
needs to be restored, we'll also have that data.
@CrystalChun CrystalChun marked this pull request as ready for review November 25, 2024 22:21
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Nov 25, 2024
Copy link

codecov bot commented Nov 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.21%. Comparing base (f148835) to head (d5c48b3).
Report is 2 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #7026      +/-   ##
==========================================
+ Coverage   68.20%   68.21%   +0.01%     
==========================================
  Files         273      273              
  Lines       39079    39085       +6     
==========================================
+ Hits        26655    26663       +8     
+ Misses      10010    10009       -1     
+ Partials     2414     2413       -1     
Files with missing lines Coverage Δ
...nternal/controller/controllers/agent_controller.go 76.55% <100.00%> (+0.11%) ⬆️

... and 2 files with indirect coverage changes

@CrystalChun
Copy link
Contributor Author

/retest

Copy link

openshift-ci bot commented Nov 26, 2024

@CrystalChun: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/edge-e2e-ai-operator-disconnected-capi d5c48b3 link false /test edge-e2e-ai-operator-disconnected-capi

Full PR test history. Your PR dashboard.

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-sigs/prow repository. I understand the commands that are listed here.

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. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants