Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions config/v1/types_cluster_operator.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,16 @@ const (
// unexpected errors are handled as operators mature.
OperatorDegraded ClusterStatusConditionType = "Degraded"

// Upgradeable indicates whether the operator safe to upgrade based on the current cluster state. When status is `False`
// administrators should not upgrade their cluster and the message field should contain a human readable description
// of what the administrator should do to allow the operator to successfully update. A missing condition, True,
// and Unknown are all treated by the CVO as allowing an upgrade.
// Upgradeable indicates whether the operator is safe to upgrade based on the
// current cluster state. When status is False, the cluster-version operator
// will prevent the cluster from performing impacted updates unless forced.
// When set on ClusterVersion, the message will explain which updates (minor
// or patch) are impacted. When set on ClusterOperator, False will block
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there an implicit hierarchy here that needs to be called out? For example, if minor version updates are not allowed, are patch version updates also automatically disallowed ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For example, if minor version updates are not allowed, are patch version updates also automatically disallowed ?

SemVer is MAJOR.MINOR.PATCH, so the two cases we have today are "blocks minor bumps, patch bumps are fine" and "blocks all bumps". So could have been minor or all here. The .spec.overrides-is-set message is:

Disabling ownership via cluster version overrides prevents upgrades. Please remove overrides before continuing.

So the actual user experience should be unambiguous.

// minor OpenShift updates. The message field should contain a human
// readable description of what the administrator should do to allow the
// cluster or operator to successfully update. The cluster-version operator
// will allow updates when this condition is not False, including when it is
// missing, True, or Unknown.
OperatorUpgradeable ClusterStatusConditionType = "Upgradeable"
)

Expand Down