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

fix: Set requeue time for etcd proxy [etcd proxy][v0.2.0] #129

Merged
merged 1 commit into from
Jun 17, 2024

Conversation

nasusoba
Copy link
Contributor

@nasusoba nasusoba commented Jun 6, 2024

We did not set a requeue time for etcd proxy machine controller, so the request will be requeued immediately. This triggered lots of requeue, which results the requeue time hits the rate limter upper limit (~16.67m which is too long for deletion). As the time between CAPI initialize the etcd removal request to the etcd member is actually removed, it might take ~ 1min. Add a requeue time of 30s so the controller will wait for a while until it pinging the api server again.

@nasusoba nasusoba changed the title Set requeue time for etcd proxy [etcd proxy][v0.2.0] fix: Set requeue time for etcd proxy [etcd proxy][v0.2.0] Jun 7, 2024
@nasusoba nasusoba marked this pull request as ready for review June 7, 2024 13:04
controlplane/controllers/machine_controller.go Outdated Show resolved Hide resolved
@@ -130,7 +130,7 @@ func (r *MachineReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ct
}
if !etcdRemoved {
logger.Info("wait k3s embedded etcd controller to remove etcd")
return ctrl.Result{Requeue: true}, err
return ctrl.Result{RequeueAfter: etcdRemovalRequeueAfter}, err
Copy link
Collaborator

Choose a reason for hiding this comment

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

can we change err to nil?

return ctrl.Result{RequeueAfter: etcdRemovalRequeueAfter}, nil

Copy link
Contributor Author

@nasusoba nasusoba Jun 14, 2024

Choose a reason for hiding this comment

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

the value of err is already nil, but we could also set it explicitly, to be super clear that there is no err

@mogliang mogliang merged commit 1fad6b8 into k3s-io:main Jun 17, 2024
5 checks passed
@nasusoba nasusoba deleted the fixetcdproxy branch June 17, 2024 05:40
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.

2 participants