Skip to content

Commit 8cd8369

Browse files
author
Han Kang
committed
add a bit about making discovery consistent
1 parent 2759e2e commit 8cd8369

File tree

1 file changed

+21
-7
lines changed
  • keps/sig-api-machinery/3903-unknown-version-interoperability-proxy

1 file changed

+21
-7
lines changed

keps/sig-api-machinery/3903-unknown-version-interoperability-proxy/README.md

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -192,15 +192,31 @@ incorrectly or objects being garbage collected mistakenly.
192192
We will use the existing `StorageVersion` API to figure out which group, versions,
193193
and resources an apiserver can serve.
194194

195+
We will also need to make discover reports the same set of resources everywhere. We propose
196+
routing discovery requests from old-apiservers to the new api-server, so that all discovery
197+
requests reflect the newest one. We specifically rule out merging discovery docs, because
198+
merging discovery is:
199+
200+
* complicated
201+
* represents an intermediate state which may not even make sense
202+
* the problems that merging discovery solves (i.e. preventing orphaned objects) can actually
203+
be solved by the dynamic feature flag KEP, so solving it here would be redundant and
204+
unnecessarily complex.
205+
206+
By routing all discovery requests to the newest apiserver, we can ensure that namespace and gc
207+
controllers do what they would be doing if the upgrade happened instantaneously.
208+
209+
195210
API server change:
196211
* A new handler is added to the stack:
212+
197213
- If the request is for a group/version/resource the apiserver doesn't have
198214
locally (we can use the StorageVersion API), it will proxy the request to
199-
one of the `serviceableBy`s if one is available. If one is not available,
200-
then we will return a 503 (there is a small possibility of a race between
201-
the controller registering the apiserver with the resources it can serve
202-
and receiving a request for a resource that is not yet available on that
203-
apiserver).
215+
one of the apiservers that is listed in the object. If an apiserver fails
216+
to respond is not available, then we will return a 503 (there is a small
217+
possibility of a race between the controller registering the apiserver
218+
with the resources it can serve and receiving a request for a resource
219+
that is not yet available on that apiserver).
204220

205221
### User Stories (Optional)
206222

@@ -256,8 +272,6 @@ TODO: security / cert stuff.
256272

257273
## Design Details
258274

259-
TODO: specific API change(s)
260-
261275
TODO: explanation of how the handler will determine a request is for a resource
262276
that should be proxied.
263277

0 commit comments

Comments
 (0)