Commit Graph

2 Commits

Author SHA1 Message Date
Arda Güçlü 89edfadfa3 Use OpenAPI to determine patch type in kubectl apply patching
Currently `kubectl apply` determines correct patch type for given
GVKs by trying to register schema and if it succeeds, it uses
strategic-merge-patch.

But OpenAPI endpoint already stores which patch types are supported
by GVKs. This PR checks OpenAPI endpoint to retrieve patch type,
if OpenAPI is enabled. If it is not enabled, patch type determination
will be done as conventional registration method.

Kubernetes-commit: cddbb0c56397448ac0489f0473a26601c1feece8
2022-06-08 13:12:16 +03:00
Sean Sullivan a18ed087c5 Move pkg/kubectl/cmd/util/openapi to staging
Kubernetes-commit: 7a64a66d61648ff0768837593d8066d828af262c
2019-07-25 21:49:49 -07:00