Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Consider moving rollback out of the Deployment controller #46934

@0xmichalis

Description

@0xmichalis

Currently, in order for a Deployment to rollback:
i. a user needs to set d.spec.rollbackTo.revision
ii. the controller notices the populated rollback spec and it updates the pod template of the deployment plus it cleans up the rollbackTo field.

Step ii. is breaking the declarative model for the Deployment API. We should consider dropping rollbackTo from the spec and instead either 1. make the deployments/{name}/rollback endpoint perform the rollback or 2. have the rollback endpoint simply return a dry-run of the rolled back Deployment which then clients can PUT.

If we do 1. we need an option for dry-run, 2. is what we do in OpenShift.

@kubernetes/sig-apps-api-reviews

ps. sparked by the decision to have rollback client-side initially for DaemonSets and StatefulSets.

Metadata

Metadata

Labels

area/workload-api/deploymentkind/api-changeCategorizes issue or PR as related to adding, removing, or otherwise changing an APIkind/cleanupCategorizes issue or PR as related to cleaning up code, process, or technical debt.priority/important-soonMust be staffed and worked on either currently, or very soon, ideally in time for the next release.sig/appsCategorizes an issue or PR as relevant to SIG Apps.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions