Skip to content

CNTRLPLANE-3173: persist lastSuccessfulEtcdBackupURL in HostedCluster status#8179

Merged
openshift-merge-bot[bot] merged 4 commits intoopenshift:mainfrom
jparrill:CNTRLPLANE-3173
Apr 10, 2026
Merged

CNTRLPLANE-3173: persist lastSuccessfulEtcdBackupURL in HostedCluster status#8179
openshift-merge-bot[bot] merged 4 commits intoopenshift:mainfrom
jparrill:CNTRLPLANE-3173

Conversation

@jparrill
Copy link
Copy Markdown
Contributor

@jparrill jparrill commented Apr 7, 2026

What this PR does / why we need it:

HCPEtcdBackup CRs are ephemeral — the retention mechanism deletes old CRs once MaxBackupCount is exceeded. When a CR is deleted, its status.snapshotURL is lost. During an OADP restore workflow, the restore operator needs the URL of the last successful etcd backup snapshot, but the HCPEtcdBackup CR that held it may no longer exist.

This PR adds a lastSuccessfulEtcdBackupURL field to HostedClusterStatus and updates the etcdbackup controller to persist the snapshot URL directly in the HostedCluster status on backup success.

Changes:

  • API: Add LastSuccessfulEtcdBackupURL string field to HostedClusterStatus, feature-gated behind HCPEtcdBackup
  • Controller: Add updateHostedClusterBackupURL() method that resolves the HostedCluster via the HCP's HostedClusterAnnotation and writes the URL to HC.Status.LastSuccessfulEtcdBackupURL on backup success
  • Tests: Add TestUpdateHostedClusterBackupURL (3 cases) and update existing success test to verify HC status propagation

Which issue(s) this PR fixes:

Fixes CNTRLPLANE-3173

Dependencies

The field is only added to HostedClusterStatus (not HostedControlPlaneStatus) since the etcdbackup controller runs in the HO and there is no precedent for the HO writing to HCP status.

Checklist:

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

🤖 Generated with Claude Code via /jira:solve [CNTRLPLANE-3173](https://redhat.atlassian.net/browse/CNTRLPLANE-3173)

Summary by CodeRabbit

  • New Features

    • Tracks the most recent successful etcd backup snapshot URL in cluster status (feature-gated, validated length).
  • Improvements

    • Prefer etcdutl for snapshot status/restore with fallback to etcdctl; clear failure if neither present.
    • Restore snapshot URL is immutable once set.
  • Tests

    • Added tests verifying backup-URL persistence, update retry behavior, and related control flows.

@openshift-ci-robot
Copy link
Copy Markdown

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: LGTM mode

@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 Apr 7, 2026
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Apr 7, 2026
@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 7, 2026

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-robot
Copy link
Copy Markdown

openshift-ci-robot commented Apr 7, 2026

@jparrill: This pull request references CNTRLPLANE-3173 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.22.0" version, but no target version was set.

Details

In response to this:

What this PR does / why we need it:

HCPEtcdBackup CRs are ephemeral — the retention mechanism deletes old CRs once MaxBackupCount is exceeded. When a CR is deleted, its status.snapshotURL is lost. During an OADP restore workflow, the restore operator needs the URL of the last successful etcd backup snapshot, but the HCPEtcdBackup CR that held it may no longer exist.

This PR adds a lastSuccessfulEtcdBackupURL field to HostedClusterStatus and updates the etcdbackup controller to persist the snapshot URL directly in the HostedCluster status on backup success.

Changes:

  • API: Add LastSuccessfulEtcdBackupURL string field to HostedClusterStatus, feature-gated behind HCPEtcdBackup
  • Controller: Add updateHostedClusterBackupURL() method that resolves the HostedCluster via the HCP's HostedClusterAnnotation and writes the URL to HC.Status.LastSuccessfulEtcdBackupURL on backup success
  • Tests: Add TestUpdateHostedClusterBackupURL (3 cases) and update existing success test to verify HC status propagation

Which issue(s) this PR fixes:

Fixes CNTRLPLANE-3173

Special notes for your reviewer:

⚠️ Dependency: This PR depends on #8139 (HCPEtcdBackup controller). The first two commits (55bbcadf8 and cb7f21ec4) are cherry-picked from that PR and should not be reviewed here — they are included solely to make this PR compile and pass CI. Once #8139 merges, the branch will be rebased and those commits will be dropped.

The field is only added to HostedClusterStatus (not HostedControlPlaneStatus) since the etcdbackup controller runs in the HO and there is no precedent for the HO writing to HCP status.

Checklist:

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

🤖 Generated with Claude Code via /jira:solve [CNTRLPLANE-3173](https://redhat.atlassian.net/browse/CNTRLPLANE-3173)

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.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 7, 2026

Important

Review skipped

Auto reviews are limited based on label configuration.

🚫 Review skipped — only excluded labels are configured. (1)
  • do-not-merge/work-in-progress

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: 7db5293e-5a20-4732-853e-e2f008c5029e

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Adds persistence of the most recent successful etcd backup URL to HostedCluster status via a new optional field HostedClusterStatus.LastSuccessfulEtcdBackupURL (JSON lastSuccessfulEtcdBackupURL, feature-gated by HCPEtcdBackup, validated length 1–2048). ManagedEtcdStorageSpec.RestoreSnapshotURL gains an immutability XValidation rule (self == oldSelf). The etcd restore script (etcd-init.sh) now prefers etcdutl for snapshot status/restore, falls back to etcdctl if absent, and errors if neither is available. The HCPEtcdBackup reconciler was extended to persist snapshot URLs from completed backup jobs into the corresponding HostedCluster status.

Sequence Diagram

sequenceDiagram
    participant BackupJob as Backup Job/Pod
    participant CloudStorage as Cloud Storage
    participant Reconciler as HCPEtcdBackupReconciler
    participant HCP as HostedControlPlane
    participant HC as HostedCluster

    BackupJob->>CloudStorage: Upload etcd snapshot
    CloudStorage-->>BackupJob: Return snapshot URL
    BackupJob->>BackupJob: Expose snapshot URL (logs/status)
    Reconciler->>BackupJob: Poll job status
    BackupJob-->>Reconciler: JobComplete with snapshot info
    Reconciler->>Reconciler: Extract snapshotURL from pod/logs
    Reconciler->>HCP: Read hosted-cluster annotation
    HCP-->>Reconciler: Provide HostedCluster reference
    Reconciler->>HC: Get HostedCluster object
    HC-->>Reconciler: Return HostedCluster
    Reconciler->>HC: Update Status.LastSuccessfulEtcdBackupURL = snapshotURL
    HC-->>Reconciler: Persisted status
Loading
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci-robot
Copy link
Copy Markdown

openshift-ci-robot commented Apr 7, 2026

@jparrill: This pull request references CNTRLPLANE-3173 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.22.0" version, but no target version was set.

Details

In response to this:

What this PR does / why we need it:

HCPEtcdBackup CRs are ephemeral — the retention mechanism deletes old CRs once MaxBackupCount is exceeded. When a CR is deleted, its status.snapshotURL is lost. During an OADP restore workflow, the restore operator needs the URL of the last successful etcd backup snapshot, but the HCPEtcdBackup CR that held it may no longer exist.

This PR adds a lastSuccessfulEtcdBackupURL field to HostedClusterStatus and updates the etcdbackup controller to persist the snapshot URL directly in the HostedCluster status on backup success.

Changes:

  • API: Add LastSuccessfulEtcdBackupURL string field to HostedClusterStatus, feature-gated behind HCPEtcdBackup
  • Controller: Add updateHostedClusterBackupURL() method that resolves the HostedCluster via the HCP's HostedClusterAnnotation and writes the URL to HC.Status.LastSuccessfulEtcdBackupURL on backup success
  • Tests: Add TestUpdateHostedClusterBackupURL (3 cases) and update existing success test to verify HC status propagation

Which issue(s) this PR fixes:

Fixes CNTRLPLANE-3173

Special notes for your reviewer:

⚠️ Dependency: This PR depends on #8139 (HCPEtcdBackup controller). The first two commits (55bbcadf8 and cb7f21ec4) are cherry-picked from that PR and should not be reviewed here — they are included solely to make this PR compile and pass CI. Once #8139 merges, the branch will be rebased and those commits will be dropped.

The field is only added to HostedClusterStatus (not HostedControlPlaneStatus) since the etcdbackup controller runs in the HO and there is no precedent for the HO writing to HCP status.

Checklist:

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

🤖 Generated with Claude Code via /jira:solve [CNTRLPLANE-3173](https://redhat.atlassian.net/browse/CNTRLPLANE-3173)

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 do-not-merge/needs-area area/api Indicates the PR includes changes for the API area/cli Indicates the PR includes changes for CLI area/control-plane-operator Indicates the PR includes changes for the control plane operator - in an OCP release area/documentation Indicates the PR includes changes for documentation area/hypershift-operator Indicates the PR includes changes for the hypershift operator and API - outside an OCP release area/testing Indicates the PR includes changes for e2e testing and removed do-not-merge/needs-area labels Apr 7, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 7, 2026

Codecov Report

❌ Patch coverage is 47.82609% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 33.90%. Comparing base (eb064c3) to head (647381e).
⚠️ Report is 5 commits behind head on main.

Files with missing lines Patch % Lines
...hift-operator/controllers/etcdbackup/reconciler.go 47.82% 8 Missing and 4 partials ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #8179   +/-   ##
=======================================
  Coverage   33.89%   33.90%           
=======================================
  Files         768      768           
  Lines       93163    93177   +14     
=======================================
+ Hits        31581    31591   +10     
- Misses      58924    58928    +4     
  Partials     2658     2658           
Files with missing lines Coverage Δ
...hift-operator/controllers/etcdbackup/reconciler.go 74.33% <47.82%> (-0.06%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jparrill
Copy link
Copy Markdown
Contributor Author

jparrill commented Apr 7, 2026

/label tide/merge-method-squash

@openshift-ci openshift-ci Bot added the tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges. label Apr 7, 2026
@jparrill jparrill marked this pull request as ready for review April 8, 2026 16:43
@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 Apr 8, 2026
@openshift-ci openshift-ci Bot requested review from cblecker and enxebre April 8, 2026 16:43
@openshift-ci-robot
Copy link
Copy Markdown

openshift-ci-robot commented Apr 8, 2026

@jparrill: This pull request references CNTRLPLANE-3173 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.22.0" version, but no target version was set.

Details

In response to this:

What this PR does / why we need it:

HCPEtcdBackup CRs are ephemeral — the retention mechanism deletes old CRs once MaxBackupCount is exceeded. When a CR is deleted, its status.snapshotURL is lost. During an OADP restore workflow, the restore operator needs the URL of the last successful etcd backup snapshot, but the HCPEtcdBackup CR that held it may no longer exist.

This PR adds a lastSuccessfulEtcdBackupURL field to HostedClusterStatus and updates the etcdbackup controller to persist the snapshot URL directly in the HostedCluster status on backup success.

Changes:

  • API: Add LastSuccessfulEtcdBackupURL string field to HostedClusterStatus, feature-gated behind HCPEtcdBackup
  • Controller: Add updateHostedClusterBackupURL() method that resolves the HostedCluster via the HCP's HostedClusterAnnotation and writes the URL to HC.Status.LastSuccessfulEtcdBackupURL on backup success
  • Tests: Add TestUpdateHostedClusterBackupURL (3 cases) and update existing success test to verify HC status propagation

Which issue(s) this PR fixes:

Fixes CNTRLPLANE-3173

Special notes for your reviewer:

⚠️ Dependency: This PR depends on #8139 (HCPEtcdBackup controller). The first two commits (55bbcadf8 and cb7f21ec4) are cherry-picked from that PR and should not be reviewed here — they are included solely to make this PR compile and pass CI. Once #8139 merges, the branch will be rebased and those commits will be dropped.

The field is only added to HostedClusterStatus (not HostedControlPlaneStatus) since the etcdbackup controller runs in the HO and there is no precedent for the HO writing to HCP status.

Checklist:

  • Subject and description added to both, commit and PR.
  • Relevant issues have been referenced.
  • This change includes docs.
  • This change includes unit tests.

🤖 Generated with Claude Code via /jira:solve [CNTRLPLANE-3173](https://redhat.atlassian.net/browse/CNTRLPLANE-3173)

Summary by CodeRabbit

  • New Features

  • Added tracking of the most recent successful etcd backup snapshot URL (gated behind HCPEtcdBackup feature).

  • Improvements

  • Enhanced etcd snapshot error detection to better identify XML error responses.

  • Improved etcd restore process to prefer modern etcdutl tool when available, with fallback support for older environments.

  • Tests

  • Added test coverage for backup URL tracking functionality.

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.

jparrill and others added 4 commits April 10, 2026 17:42
Add LastSuccessfulEtcdBackupURL field to HostedClusterStatus so the most
recent successful etcd backup snapshot URL survives HCPEtcdBackup CR
retention/deletion. The etcdbackup controller writes the URL directly to
the HostedCluster status on backup success, resolving the URL from the
HCP's HostedClusterAnnotation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
Regenerate after adding LastSuccessfulEtcdBackupURL to HostedClusterStatus.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
Add CEL validation rule to prevent day-2 modifications of the
restoreSnapshotURL field. This ensures the field can only be set at
creation time, which aligns with the existing API contract and makes
the OADP restoration workflow safe without changing the field semantics.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
…bility

Generated CRD manifests reflecting the new CEL validation rule
on the restoreSnapshotURL field.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
@enxebre
Copy link
Copy Markdown
Member

enxebre commented Apr 10, 2026

/approve

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 10, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: enxebre, jparrill

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

The pull request process is described here

Details 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 Apr 10, 2026
@sdminonne
Copy link
Copy Markdown
Contributor

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Apr 10, 2026
@openshift-merge-bot
Copy link
Copy Markdown
Contributor

Scheduling tests matching the pipeline_run_if_changed or not excluded by pipeline_skip_if_only_changed parameters:
/test e2e-aks-4-21
/test e2e-aws-4-21
/test e2e-aks
/test e2e-aws
/test e2e-aws-upgrade-hypershift-operator
/test e2e-azure-self-managed
/test e2e-kubevirt-aws-ovn-reduced
/test e2e-v2-aws

@jparrill
Copy link
Copy Markdown
Contributor Author

@openshift-ci-robot openshift-ci-robot added the verified Signifies that the PR passed pre-merge verification criteria label Apr 10, 2026
@openshift-ci-robot
Copy link
Copy Markdown

@jparrill: The verified label has been added.

Details

In response to this:

/verified bypass

More info in here: https://redhat-internal.slack.com/archives/G01QS0P2F6W/p1775814810815969?thread_ts=1775808691.857879&cid=G01QS0P2F6W

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.

@jparrill
Copy link
Copy Markdown
Contributor Author

/retest-required

@openshift-ci
Copy link
Copy Markdown
Contributor

openshift-ci Bot commented Apr 10, 2026

@jparrill: all tests passed!

Full PR test history. Your PR dashboard.

Details

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.

@openshift-merge-bot openshift-merge-bot Bot merged commit 4402b11 into openshift:main Apr 10, 2026
42 checks passed
mehabhalodiya pushed a commit to mehabhalodiya/hypershift that referenced this pull request Apr 13, 2026
… status (openshift#8179)

* feat(CNTRLPLANE-3173): persist lastSuccessfulEtcdBackupURL in HC status

Add LastSuccessfulEtcdBackupURL field to HostedClusterStatus so the most
recent successful etcd backup snapshot URL survives HCPEtcdBackup CR
retention/deletion. The etcdbackup controller writes the URL directly to
the HostedCluster status on backup success, resolving the URL from the
HCP's HostedClusterAnnotation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* chore(generated): regenerate CRDs, clients, vendor, and docs

Regenerate after adding LastSuccessfulEtcdBackupURL to HostedClusterStatus.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* feat(CNTRLPLANE-2678): enforce restoreSnapshotURL immutability via CEL

Add CEL validation rule to prevent day-2 modifications of the
restoreSnapshotURL field. This ensures the field can only be set at
creation time, which aligns with the existing API contract and makes
the OADP restoration workflow safe without changing the field semantics.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* chore(CNTRLPLANE-2678): regenerate CRDs for restoreSnapshotURL immutability

Generated CRD manifests reflecting the new CEL validation rule
on the restoreSnapshotURL field.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

---------

Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
bryan-cox pushed a commit to bryan-cox/hypershift that referenced this pull request Apr 13, 2026
… status (openshift#8179)

* feat(CNTRLPLANE-3173): persist lastSuccessfulEtcdBackupURL in HC status

Add LastSuccessfulEtcdBackupURL field to HostedClusterStatus so the most
recent successful etcd backup snapshot URL survives HCPEtcdBackup CR
retention/deletion. The etcdbackup controller writes the URL directly to
the HostedCluster status on backup success, resolving the URL from the
HCP's HostedClusterAnnotation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* chore(generated): regenerate CRDs, clients, vendor, and docs

Regenerate after adding LastSuccessfulEtcdBackupURL to HostedClusterStatus.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* feat(CNTRLPLANE-2678): enforce restoreSnapshotURL immutability via CEL

Add CEL validation rule to prevent day-2 modifications of the
restoreSnapshotURL field. This ensures the field can only be set at
creation time, which aligns with the existing API contract and makes
the OADP restoration workflow safe without changing the field semantics.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* chore(CNTRLPLANE-2678): regenerate CRDs for restoreSnapshotURL immutability

Generated CRD manifests reflecting the new CEL validation rule
on the restoreSnapshotURL field.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

---------

Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
bryan-cox pushed a commit to bryan-cox/hypershift that referenced this pull request Apr 14, 2026
… status (openshift#8179)

* feat(CNTRLPLANE-3173): persist lastSuccessfulEtcdBackupURL in HC status

Add LastSuccessfulEtcdBackupURL field to HostedClusterStatus so the most
recent successful etcd backup snapshot URL survives HCPEtcdBackup CR
retention/deletion. The etcdbackup controller writes the URL directly to
the HostedCluster status on backup success, resolving the URL from the
HCP's HostedClusterAnnotation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* chore(generated): regenerate CRDs, clients, vendor, and docs

Regenerate after adding LastSuccessfulEtcdBackupURL to HostedClusterStatus.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* feat(CNTRLPLANE-2678): enforce restoreSnapshotURL immutability via CEL

Add CEL validation rule to prevent day-2 modifications of the
restoreSnapshotURL field. This ensures the field can only be set at
creation time, which aligns with the existing API contract and makes
the OADP restoration workflow safe without changing the field semantics.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

* chore(CNTRLPLANE-2678): regenerate CRDs for restoreSnapshotURL immutability

Generated CRD manifests reflecting the new CEL validation rule
on the restoreSnapshotURL field.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>

---------

Signed-off-by: Juan Manuel Parrilla Madrid <jparrill@redhat.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
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. area/api Indicates the PR includes changes for the API area/cli Indicates the PR includes changes for CLI area/control-plane-operator Indicates the PR includes changes for the control plane operator - in an OCP release area/documentation Indicates the PR includes changes for documentation area/hypershift-operator Indicates the PR includes changes for the hypershift operator and API - outside an OCP release area/testing Indicates the PR includes changes for e2e testing jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges. verified Signifies that the PR passed pre-merge verification criteria

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants