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

Feature/auto restart for update #88

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

debbyku
Copy link

@debbyku debbyku commented Aug 20, 2021

It is to provide auto restart feature when updating redis cluster features, e.g. cpu, memory, image.
It will also update pvc storage size.

Comment on lines 46 to 52
origss, err := s.GetStatefulSet(ss.Namespace, ss.Name)
if err != nil {
return err
}
patch := client.MergeFrom(origss.DeepCopy())
ss.Spec.Template.DeepCopyInto(&origss.Spec.Template)
return s.client.Patch(context.TODO(), origss, patch)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @debbyku,
With this change I was able to restart pods during resource updates, but the change of the number of replicas is not working anymore. Can you confirm it?

Thanks!!!

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I missed the replicas update here as the "replicas" is not in ss.Spec.Template.

I've modified the codes and and push again.

Thanks.

@vl-shopback
Copy link

why it is not merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants