K8SPXC-1152: restore stucks on operator restart#1610
Merged
Conversation
inelpandzic
previously approved these changes
Feb 6, 2024
egegunes
reviewed
Feb 6, 2024
Comment on lines
92
to
96
| rr := reconcile.Result{ | ||
| RequeueAfter: time.Second * 5, | ||
| } |
Contributor
There was a problem hiding this comment.
honestly I'm not happy to depend on RequeueAfter but I guess there's no other way
Contributor
Author
There was a problem hiding this comment.
There is a way to not depend on RequeueAfter, but it will take more time to implement. I would like to do it in a separate PR.
inelpandzic
previously approved these changes
Feb 13, 2024
https://perconadev.atlassian.net/browse/K8SPXC-1152 fix unit test fix for pvc restores refactor fix tests fix `security-context` test add unit-test improvements add TODO comment
f86ff81 to
df69c14
Compare
egegunes
requested changes
Jan 21, 2025
| var oldHAProxySize int32 | ||
| if cluster.Spec.HAProxy != nil { | ||
| oldHAProxySize = cluster.Spec.HAProxy.Size | ||
| switch statusState { |
Contributor
There was a problem hiding this comment.
maybe we should move code for each case to a separate function? this would make code more readable
gkech
reviewed
Jan 21, 2025
pkg/controller/pxcrestore/util.go
Outdated
|
|
||
| func setStatus(ctx context.Context, cl client.Client, cr *api.PerconaXtraDBClusterRestore, state api.BcpRestoreStates, comments string) error { | ||
| cr.Status.State = state | ||
| switch state { |
Contributor
There was a problem hiding this comment.
Is this swtich here really needed since are handling only one case?
gkech
previously approved these changes
Feb 7, 2025
This reverts commit 5972d05.
gkech
approved these changes
Feb 13, 2025
nmarukovich
approved these changes
Feb 14, 2025
egegunes
approved these changes
Feb 25, 2025
Collaborator
commit: 4eddfda |
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.
https://perconadev.atlassian.net/browse/K8SPXC-1152
CHANGE DESCRIPTION
Problem:
If operator pod is restarted during a restore, it can't continue to the restore process.
Cause:
The current design of the restore process is not designed to continue on operator restart.
Solution:
We should refactor the restore code so that the operator can catch up with the current state of the restore and continue.
CHECKLIST
Jira
Needs Doc) and QA (Needs QA)?Tests
compare/*-oc.yml)?Config/Logging/Testability