version

package
v0.0.0-...-c3f02f9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 22, 2026 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetZStreamOffset

func GetZStreamOffset(channel string) uint

GetZStreamOffset returns the offset from the tip of a channel to use when selecting a z-stream control plane version (offset 0 = the most recent release). The stable channel group uses the penultimate release (offset 1) to avoid selecting a brand-new stable z-stream immediately; all other channel groups use the tip.

func NewControlPlaneActiveVersionController

func NewControlPlaneActiveVersionController(
	resourcesDBClient corecosmosstorage.ResourcesDBClient,
	serviceProviderClusterLister corelisters.ServiceProviderClusterLister,
	informers coreinformers.BackendInformers,
	kubeApplierInformers *unionkubeapplierinformers.UnionKubeApplierInformers,
	readDesireLister kubeapplierlisters.ReadDesireLister,
) controllerutils.Controller

NewControlPlaneActiveVersionController creates a new controller that updates Status.ControlPlaneVersion.ActiveVersions from the per-cluster ReadDesire's observed HostedCluster.

func NewControlPlaneDesiredVersionController

func NewControlPlaneDesiredVersionController(
	clock utilsclock.PassiveClock,
	resourcesDBClient corecosmosstorage.ResourcesDBClient,
	clusterLister corelisters.ClusterLister,
	clusterServiceClient ocm.ClusterServiceClientSpec,
	activeOperationLister corelisters.ActiveOperationLister,
	serviceProviderClusterLister corelisters.ServiceProviderClusterLister,
	nodePoolLister corelisters.NodePoolLister,
	serviceProviderNodePoolLister corelisters.ServiceProviderNodePoolLister,
	informers coreinformers.BackendInformers,
) controllerutils.Controller

NewControlPlaneDesiredVersionController creates a new controller that manages the control plane desired version for every cluster: it seeds the initial desired version and drives z-stream and y-stream upgrades thereafter, based on the OCPVersion logic documented in the ServiceProviderCluster type.

func NewTriggerControlPlaneUpgradeController

func NewTriggerControlPlaneUpgradeController(
	clock utilsclock.PassiveClock,
	resourcesDBClient corecosmosstorage.ResourcesDBClient,
	clusterServiceClient ocm.ClusterServiceClientSpec,
	activeOperationLister corelisters.ActiveOperationLister,
	serviceProviderClusterLister corelisters.ServiceProviderClusterLister,
	informers coreinformers.BackendInformers,
	kubeApplierInformers *unionkubeapplierinformers.UnionKubeApplierInformers,
) controllerutils.Controller

NewTriggerControlPlaneUpgradeController creates a new controller that triggers control plane upgrades. It monitors clusters where the desired version differs from the actual version and calls the version service API to initiate the upgrade.

The version service API is idempotent:

  • If desiredVersion == current cluster version: NOOP
  • Otherwise: Initiate the upgrade to desiredVersion

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL