Skip to content

Commit 03e1e9b

Browse files
committed
KEP-1965: clarify design details around storageversiongc controller running in kube-controller-manager
Signed-off-by: Andrew Sy Kim <[email protected]>
1 parent 3fe6a38 commit 03e1e9b

File tree

1 file changed

+7
-6
lines changed
  • keps/sig-api-machinery/1965-kube-apiserver-identity

1 file changed

+7
-6
lines changed

keps/sig-api-machinery/1965-kube-apiserver-identity/README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -125,15 +125,16 @@ logic [already written](https://github.com/kubernetes/kubernetes/tree/master/pkg
125125
will be re-used. The heartbeat controller will be added to kube-apiserver in a
126126
post-start hook.
127127

128-
Each kube-apiserver will refresh its Lease every 10s by default. A GC controller
129-
will watch the Lease API using an informer, and periodically resync its local
130-
cache. On processing an item, the controller will delete the Lease if the last
131-
`renewTime` was more than `leaseDurationSeconds` ago (default to 1h). The
132-
default `leaseDurationSeconds` is chosen to be way longer than the default
128+
Each kube-apiserver will run a lease controller in a post-start-hook to refresh
129+
its Lease every 10s by default. A separate controller named [storageversiongc](https://github.com/kubernetes/kubernetes/blob/master/pkg/controller/storageversiongc/gc_controller.go)
130+
running in kube-controller-manager will watch the Lease API using an informer, and
131+
periodically resync its local cache. On processing an item, the `storageversiongc` controller
132+
will delete the Lease if the last `renewTime` was more than `leaseDurationSeconds` ago (default to 1h).
133+
The default `leaseDurationSeconds` is chosen to be way longer than the default
133134
refresh period, to tolerate clock skew and/or accidental refresh failure. The
134135
default resync period is 1h. By default, assuming negligible clock skew, a Lease
135136
will be deleted if the kube-apiserver fails to refresh its Lease for one to two
136-
hours. The GC controller will run in kube-controller-manager, to leverage leader
137+
hours. The `storageversiongc` controller will run in kube-controller-manager, to leverage leader
137138
election and reduce conflicts.
138139

139140
The refresh rate, lease duration will be configurable through kube-apiserver

0 commit comments

Comments
 (0)