rukpak icon indicating copy to clipboard operation
rukpak copied to clipboard

Add CLI provisioner flag for enabling leader election

Open timflannagan opened this issue 3 years ago • 7 comments

Placeholder for now: It looks like the core set of provisioners don't have a way to enable leader election mechanisms that are present in controller runtime.

timflannagan avatar Sep 22 '22 20:09 timflannagan

Saw this while doing some downstream testing. I think we'd want to at least add a CLI flag toggling leader election in the short term. Ideally, this would be the default behavior, and you'd toggle off leader election during dev workflows.

timflannagan avatar Sep 22 '22 20:09 timflannagan

FYI @joelanford

timflannagan avatar Sep 22 '22 20:09 timflannagan

The provisioner executable has the leader-elect flag and its default is false

flag.BoolVar(&enableLeaderElection, "leader-elect", false,
		"Enable leader election for controller manager. "+
			"Enabling this will ensure there is only one active controller manager.")

The deployment.yaml doesn't have the flag set. So it's false by default. This flag don't have any effect with replicas: 1 in the deployment.yaml.

akihikokuroda avatar Sep 28 '22 18:09 akihikokuroda

Yep, you're right (and I'm blind). I think leader election would still be relevant here as configuring a single replica for the provisioner deployment can result in new replicas being rolled out over time, and those new replicas could specify a bad container image, or that container image would result in runtime failures, etc. and the leader election mechanisms being enabled would help smooth out that transistion between provisioner pods.

timflannagan avatar Sep 28 '22 18:09 timflannagan

This issue has become stale because it has been open 60 days with no activity. The maintainers of this repo will remove this label during issue triage or it will be removed automatically after an update. Adding the lifecycle/frozen label will cause this issue to ignore lifecycle events.

github-actions[bot] avatar Nov 29 '22 00:11 github-actions[bot]

@joelanford Just going through my open list of issues to see what can be closed and noticed this wasn't ever picked up. Might be worth tackling if this is still an issue before rukpak hits production.

timflannagan avatar Jun 13 '23 17:06 timflannagan

This issue has become stale because it has been open 60 days with no activity. The maintainers of this repo will remove this label during issue triage or it will be removed automatically after an update. Adding the lifecycle/frozen label will cause this issue to ignore lifecycle events.

github-actions[bot] avatar Aug 14 '23 00:08 github-actions[bot]