remove unnecessary field MantleRestore.status.pool#186
Merged
Conversation
To avoid error on go v1.25 environment Signed-off-by: Yuji Ito <llamerada.jp@gmail.com>
`MantleRestore.status.pool` was kept to delete MR without MantleBackup. But the procedure of deletion has changed, and the field is unused. Signed-off-by: Yuji Ito <llamerada.jp@gmail.com>
e70eecf to
639f65a
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR removes the Pool field from the MantleRestore status object and refactors the restore process to fetch the pool name directly from the PV manifest at the point of use rather than storing it in the status. This change simplifies the API by eliminating redundant state storage and reduces unnecessary status updates during restoration.
Key changes:
- Removed
Poolfield fromMantleRestoreStatusstruct and CRD definitions - Refactored pool retrieval to happen locally in
cloneImageFromBackupinstead of storing in status - Updated Go dependencies (go.uber.org/mock and various golang.org/x packages)
Reviewed Changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| api/v1/mantlerestore_types.go | Removed Pool field from MantleRestoreStatus struct |
| internal/controller/mantlerestore_controller.go | Removed status update logic for Pool; extracted pool locally in cloneImageFromBackup function |
| config/crd/bases/mantle.cybozu.io_mantlerestores.yaml | Removed pool field from CRD status specification |
| charts/mantle-cluster-wide/templates/mantle.cybozu.io_mantlerestores.yaml | Removed pool field from Helm chart CRD template |
| test/e2e/singlek8s/restore_test.go | Removed Pool field from test status initialization |
| go.mod | Updated go.uber.org/mock and golang.org/x dependencies |
| go.sum | Updated checksums for dependency changes |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
skoya76
approved these changes
Nov 10, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MantleRestore.status.poolwas kept to delete MR without MantleBackup. But the procedure of deletion has changed, and the field is unused.