|
|
ClusterObjectSets is a Technology Preview feature only. Technology Preview features are not supported with Red Hat production service level agreements (SLAs) and might not be functionally complete. Red Hat does not recommend using them in production. These features provide early access to upcoming product features, enabling customers to test functionality and provide feedback during the development process.
|
As part of Operator Lifecycle Manager (OLM) v1, the operator-controller creates ClusterObjectSet resources when you install or upgrade content with a ClusterExtension object. ClusterObjectSet objects enable safe, phased rollouts of Kubernetes resources.
A ClusterObjectSet object is a cluster-scoped resource. It is not content that you install. It is the controller’s internal record for one revision of your ClusterExtension object. It rolls out related resources sequentially with built-in readiness checks between phases.
A ClusterObjectSet object solves several problems when managing sets of related Kubernetes resources:
- Immutable revision content
-
The revision number, phases, objects, and collision protection strategy are immutable, that is, they cannot change once set. This provides a clear audit trail of what was deployed at each revision.
- Phased rollout
-
Resources are grouped into phases, for example, CRDs before Deployments, and are deployed sequentially. A phase only progresses after all its objects pass readiness probes. Manifests are organized into phases, applied to the cluster, and must pass some status probes before they progress to the next phase. This avoids incomplete installs.
- Safe transitions
-
During upgrades, both old and new revisions remain active until the new revision succeeds. Object ownership transitions between revisions automatically.
- Single ownership
-
Each resource can only be managed by one ClusterObjectSet at a time, preventing conflicts.
- Large resource support
-
Object manifests can be stored inline or externalized into secrets, allowing bundles larger than the etcd 1.5 MiB object size limit.
|
|
Archived ClusterObjectSet revisions stay on the cluster as a history of what was applied for that ClusterExtension object.
|
Each ClusterObjectSet contains the following content:
- A revision number
-
A permanent, sequential integer that identifies the version. When the bundle version changes, it creates a new revision. During an upgrade, the old and new revision can both be active until the new one finishes. Older revisions are archived.
- A lifecycle state
-
This shows the status of the ClusterObjectSet, which can be Active (managed and reconciled) or Archived. The lifecycleState transitions from Active to Archived but not back.
- A list of phases
-
Objects within a ClusterObjectSet are organized into phases. Each phase groups related resources, and phases are applied sequentially. Within a phase, all objects are applied simultaneously in no particular order.
- A collision protection strategy
-
Controls whether a ClusterObjectSet can adopt pre-existing objects on the cluster.
- Status conditions
-
Indicates whether the revision is actively rolling out and reports rollout progress, availability, and success.
At most, one ClusterObjectSet manages a given cluster object at a time. Very large bundles store manifests in Secret objects so that size limits do not block installs or upgrades.
Additionally, support for management of large object bundles created by ClusterObjectSet is provided. ClusterObjectSet embeds Kubernetes manifests in .spec.phases[].objects[].object. Currently, with up to 20 phases and 50 objects per phase, they can exceed the etcd 1.5 MiB object size limit. Large Operators with many CRDs, Deployments, RBAC rules, and webhook configurations frequently hit this limit, causing the API server to reject the ClusterObjectSet and fail installation or upgrade.
To solve this, objects can be externalized into Secret resources using per-object references. The phases data is immutable and only consumed by the revision reconciler, making it suitable for externalization.