Closed m-messiah closed 1 year ago
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: christopherhein, m-messiah
The full list of commands accepted by this bot can be found here.
The pull request process is described here
What this PR does / why we need it: The PR adds a new flag
--leader-elect-resource-lock
to define the type of leader election resource lock (configmapleases, configmaps or leases). Current default behaviour of controller-runtime sets it to configmapleases, so the controller creates and updates two objects now - ConfigMap and Lease. Adding the flag would help operators to switch controller to use leases only to reduce load to the API and network.The PR also deprecates the flag
--le-cm-name
because it was usingcm
in it, that could be confusing after the switch to leases; so it introduces the new flag--leader-elect-resource-name
with the fallback to--le-cm-name
if it is set explicitly.