diff --git a/api/v1alpha1/clusterextension_types.go b/api/v1alpha1/clusterextension_types.go
index b68f7f2a7..ad99e7251 100644
--- a/api/v1alpha1/clusterextension_types.go
+++ b/api/v1alpha1/clusterextension_types.go
@@ -422,15 +422,12 @@ const (
TypeChannelDeprecated = "ChannelDeprecated"
TypeBundleDeprecated = "BundleDeprecated"
- ReasonSuccess = "Succeeded"
+ ReasonSucceeded = "Succeeded"
ReasonDeprecated = "Deprecated"
ReasonFailed = "Failed"
ReasonBlocked = "Blocked"
ReasonRetrying = "Retrying"
- ReasonErrorGettingClient = "ErrorGettingClient"
- ReasonErrorGettingReleaseState = "ErrorGettingReleaseState"
-
CRDUpgradeSafetyPolicyEnabled CRDUpgradeSafetyPolicy = "Enabled"
CRDUpgradeSafetyPolicyDisabled CRDUpgradeSafetyPolicy = "Disabled"
)
@@ -447,11 +444,9 @@ func init() {
)
// TODO(user): add Reasons from above
conditionsets.ConditionReasons = append(conditionsets.ConditionReasons,
- ReasonSuccess,
+ ReasonSucceeded,
ReasonDeprecated,
ReasonFailed,
- ReasonErrorGettingClient,
- ReasonErrorGettingReleaseState,
ReasonBlocked,
ReasonRetrying,
)
@@ -481,8 +476,7 @@ type ClusterExtensionStatus struct {
//
// The global set of condition types are:
// - "Installed", represents whether or not the a bundle has been installed for this ClusterExtension
- // - "Resolved", represents whether or not a bundle was found that satisfies the selection criteria outlined in the spec
- // - "Unpacked", represents whether or not the bundle contents have been successfully unpacked
+ // - "Progressing", represents whether or not the ClusterExtension is progressing towards a new state
//
// When the ClusterExtension is sourced from a catalog, the following conditions are also possible:
// - "Deprecated", represents an aggregation of the PackageDeprecated, ChannelDeprecated, and BundleDeprecated condition types
@@ -491,8 +485,11 @@ type ClusterExtensionStatus struct {
// - "BundleDeprecated", represents whether or not the installed bundle is deprecated
//
// The current set of reasons are:
- // - "Success", this reason is set on the "Unpacked", "Resolved" and "Installed" conditions when unpacking a bundle's content, resolution and installation/upgrading is successful
- // - "Failed", this reason is set on the "Unpacked", "Resolved" and "Installed" conditions when an error has occurred while unpacking the contents of a bundle, during resolution or installation.
+ // - "Succeeded", this reason is set on the "Installed" and "Progressing" conditions when initial installation and progressing to a new state is successful
+ // - "Failed", this reason is set on the "Installed" condition when an error has occurred while performing the initial installation.
+ // - "Blocked", this reason is set on the "Progressing" condition when the ClusterExtension controller has encountered an error that requires manual intervention for recovery
+ // - "Retrying", this reason is set on the "Progressing" condition when the ClusterExtension controller has encountered an error that could be resolved on subsequent reconciliation attempts
+ // - "Deprecated", this reason is set on the "Deprecated", "PackageDeprecated", "ChannelDeprecated", and "BundleDeprecated" conditions to signal that the installed package has been deprecated at the particular scope
//
//
// +patchMergeKey=type
diff --git a/cmd/manager/main.go b/cmd/manager/main.go
index 947fca826..a64ba4ac2 100644
--- a/cmd/manager/main.go
+++ b/cmd/manager/main.go
@@ -30,7 +30,6 @@ import (
"github.com/spf13/pflag"
apiextensionsv1client "k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset/typed/apiextensions/v1"
k8slabels "k8s.io/apimachinery/pkg/labels"
- "k8s.io/apimachinery/pkg/selection"
corev1client "k8s.io/client-go/kubernetes/typed/core/v1"
_ "k8s.io/client-go/plugin/pkg/client/auth"
"k8s.io/klog/v2"
@@ -56,7 +55,6 @@ import (
"github.com/operator-framework/operator-controller/internal/features"
"github.com/operator-framework/operator-controller/internal/finalizers"
"github.com/operator-framework/operator-controller/internal/httputil"
- "github.com/operator-framework/operator-controller/internal/labels"
"github.com/operator-framework/operator-controller/internal/resolve"
"github.com/operator-framework/operator-controller/internal/rukpak/preflights/crdupgradesafety"
"github.com/operator-framework/operator-controller/internal/rukpak/source"
@@ -122,13 +120,6 @@ func main() {
systemNamespace = podNamespace()
}
- dependentRequirement, err := k8slabels.NewRequirement(labels.OwnerKindKey, selection.In, []string{ocv1alpha1.ClusterExtensionKind})
- if err != nil {
- setupLog.Error(err, "unable to create dependent label selector for cache")
- os.Exit(1)
- }
- dependentSelector := k8slabels.NewSelector().Add(*dependentRequirement)
-
setupLog.Info("set up manager")
mgr, err := ctrl.NewManager(ctrl.GetConfigOrDie(), ctrl.Options{
Scheme: scheme.Scheme,
@@ -144,7 +135,7 @@ func main() {
DefaultNamespaces: map[string]crcache.Config{
systemNamespace: {LabelSelector: k8slabels.Everything()},
},
- DefaultLabelSelector: dependentSelector,
+ DefaultLabelSelector: k8slabels.Nothing(),
},
// LeaderElectionReleaseOnCancel defines if the leader should step down voluntarily
// when the Manager ends. This requires the binary to immediately end when the
diff --git a/config/base/crd/bases/olm.operatorframework.io_clusterextensions.yaml b/config/base/crd/bases/olm.operatorframework.io_clusterextensions.yaml
index f24871f00..61b81606b 100644
--- a/config/base/crd/bases/olm.operatorframework.io_clusterextensions.yaml
+++ b/config/base/crd/bases/olm.operatorframework.io_clusterextensions.yaml
@@ -476,8 +476,7 @@ spec:
The global set of condition types are:
- "Installed", represents whether or not the a bundle has been installed for this ClusterExtension
- - "Resolved", represents whether or not a bundle was found that satisfies the selection criteria outlined in the spec
- - "Unpacked", represents whether or not the bundle contents have been successfully unpacked
+ - "Progressing", represents whether or not the ClusterExtension is progressing towards a new state
When the ClusterExtension is sourced from a catalog, the following conditions are also possible:
- "Deprecated", represents an aggregation of the PackageDeprecated, ChannelDeprecated, and BundleDeprecated condition types
@@ -486,8 +485,11 @@ spec:
- "BundleDeprecated", represents whether or not the installed bundle is deprecated
The current set of reasons are:
- - "Success", this reason is set on the "Unpacked", "Resolved" and "Installed" conditions when unpacking a bundle's content, resolution and installation/upgrading is successful
- - "Failed", this reason is set on the "Unpacked", "Resolved" and "Installed" conditions when an error has occurred while unpacking the contents of a bundle, during resolution or installation.
+ - "Succeeded", this reason is set on the "Installed" and "Progressing" conditions when initial installation and progressing to a new state is successful
+ - "Failed", this reason is set on the "Installed" condition when an error has occurred while performing the initial installation.
+ - "Blocked", this reason is set on the "Progressing" condition when the ClusterExtension controller has encountered an error that requires manual intervention for recovery
+ - "Retrying", this reason is set on the "Progressing" condition when the ClusterExtension controller has encountered an error that could be resolved on subsequent reconciliation attempts
+ - "Deprecated", this reason is set on the "Deprecated", "PackageDeprecated", "ChannelDeprecated", and "BundleDeprecated" conditions to signal that the installed package has been deprecated at the particular scope
items:
description: Condition contains details for one aspect of the current
state of this API Resource.
diff --git a/docs/api-reference/operator-controller-api-reference.md b/docs/api-reference/operator-controller-api-reference.md
index 0c5aced18..86bd90190 100644
--- a/docs/api-reference/operator-controller-api-reference.md
+++ b/docs/api-reference/operator-controller-api-reference.md
@@ -192,7 +192,7 @@ _Appears in:_
| Field | Description | Default | Validation |
| --- | --- | --- | --- |
| `install` _[ClusterExtensionInstallStatus](#clusterextensioninstallstatus)_ | | | |
-| `conditions` _[Condition](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.31/#condition-v1-meta) array_ | conditions is a representation of the current state for this ClusterExtension.
The status is represented by a set of "conditions".
Each condition is generally structured in the following format:
- Type: a string representation of the condition type. More or less the condition "name".
- Status: a string representation of the state of the condition. Can be one of ["True", "False", "Unknown"].
- Reason: a string representation of the reason for the current state of the condition. Typically useful for building automation around particular Type+Reason combinations.
- Message: a human readable message that further elaborates on the state of the condition
The global set of condition types are:
- "Installed", represents whether or not the a bundle has been installed for this ClusterExtension
- "Resolved", represents whether or not a bundle was found that satisfies the selection criteria outlined in the spec
- "Unpacked", represents whether or not the bundle contents have been successfully unpacked
When the ClusterExtension is sourced from a catalog, the following conditions are also possible:
- "Deprecated", represents an aggregation of the PackageDeprecated, ChannelDeprecated, and BundleDeprecated condition types
- "PackageDeprecated", represents whether or not the package specified in the spec.source.catalog.packageName field has been deprecated
- "ChannelDeprecated", represents whether or not any channel specified in spec.source.catalog.channels has been deprecated
- "BundleDeprecated", represents whether or not the installed bundle is deprecated
The current set of reasons are:
- "Success", this reason is set on the "Unpacked", "Resolved" and "Installed" conditions when unpacking a bundle's content, resolution and installation/upgrading is successful
- "Failed", this reason is set on the "Unpacked", "Resolved" and "Installed" conditions when an error has occurred while unpacking the contents of a bundle, during resolution or installation. | | |
+| `conditions` _[Condition](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.31/#condition-v1-meta) array_ | conditions is a representation of the current state for this ClusterExtension.
The status is represented by a set of "conditions".
Each condition is generally structured in the following format:
- Type: a string representation of the condition type. More or less the condition "name".
- Status: a string representation of the state of the condition. Can be one of ["True", "False", "Unknown"].
- Reason: a string representation of the reason for the current state of the condition. Typically useful for building automation around particular Type+Reason combinations.
- Message: a human readable message that further elaborates on the state of the condition
The global set of condition types are:
- "Installed", represents whether or not the a bundle has been installed for this ClusterExtension
- "Progressing", represents whether or not the ClusterExtension is progressing towards a new state
When the ClusterExtension is sourced from a catalog, the following conditions are also possible:
- "Deprecated", represents an aggregation of the PackageDeprecated, ChannelDeprecated, and BundleDeprecated condition types
- "PackageDeprecated", represents whether or not the package specified in the spec.source.catalog.packageName field has been deprecated
- "ChannelDeprecated", represents whether or not any channel specified in spec.source.catalog.channels has been deprecated
- "BundleDeprecated", represents whether or not the installed bundle is deprecated
The current set of reasons are:
- "Succeeded", this reason is set on the "Installed" and "Progressing" conditions when initial installation and progressing to a new state is successful
- "Failed", this reason is set on the "Installed" condition when an error has occurred while performing the initial installation.
- "Blocked", this reason is set on the "Progressing" condition when the ClusterExtension controller has encountered an error that requires manual intervention for recovery
- "Retrying", this reason is set on the "Progressing" condition when the ClusterExtension controller has encountered an error that could be resolved on subsequent reconciliation attempts
- "Deprecated", this reason is set on the "Deprecated", "PackageDeprecated", "ChannelDeprecated", and "BundleDeprecated" conditions to signal that the installed package has been deprecated at the particular scope | | |
#### PreflightConfig
diff --git a/docs/tutorials/add-catalog.md b/docs/tutorials/add-catalog.md
index 60466ed23..ad3ae06bb 100644
--- a/docs/tutorials/add-catalog.md
+++ b/docs/tutorials/add-catalog.md
@@ -99,12 +99,12 @@ This catalog is distributed as an image [quay.io/operatorhubio/catalog](https://
API Version: olm.operatorframework.io/v1alpha1
Kind: ClusterCatalog
Metadata:
- Creation Timestamp: 2024-03-12T19:34:50Z
- Finalizers:
+ Creation Timestamp: 2024-10-02T19:51:24Z
+ Finalizers:
olm.operatorframework.io/delete-server-cache
- Generation: 2
- Resource Version: 6469
- UID: 2e2778cb-dda6-4645-96b7-992e8dd37503
+ Generation: 1
+ Resource Version: 33321
+ UID: 52894532-0646-41a5-8285-c7f48bba49e4
Spec:
Priority: 0
Source:
diff --git a/docs/tutorials/install-extension.md b/docs/tutorials/install-extension.md
index 4841bb518..95bdb5c3a 100644
--- a/docs/tutorials/install-extension.md
+++ b/docs/tutorials/install-extension.md
@@ -103,35 +103,73 @@ For information on determining the ServiceAccount's permission, please see [Deri
??? success
``` text title="Example output"
- Name: my-camel-k
+ Name: argocd
Namespace:
Labels:
Annotations:
API Version: olm.operatorframework.io/v1alpha1
Kind: ClusterExtension
Metadata:
- Creation Timestamp: 2024-03-15T15:03:47Z
- Generation: 1
- Resource Version: 7691
- UID: d756879f-217d-4ebe-85b1-8427bbb2f1df
+ Creation Timestamp: 2024-10-03T16:02:40Z
+ Finalizers:
+ olm.operatorframework.io/cleanup-unpack-cache
+ olm.operatorframework.io/cleanup-contentmanager-cache
+ Generation: 2
+ Resource Version: 1174
+ UID: 0fcaf3f5-d142-4c7e-8d88-c88a549f7764
Spec:
- Package Name: camel-k
- Upgrade Constraint Policy: Enforce
+ Install:
+ Namespace: argocd
+ Service Account:
+ Name: argocd-installer
+ Source:
+ Catalog:
+ Package Name: argocd-operator
+ Selector:
+ Upgrade Constraint Policy: CatalogProvided
+ Version: 0.6.0
+ Source Type: Catalog
Status:
- Conditions:
- Last Transition Time: 2024-03-15T15:03:50Z
- Message: resolved to "quay.io/operatorhubio/camel-k@sha256:d2b74c43ec8f9294450c9dcf2057be328d0998bb924ad036db489af79d1b39c3"
- Observed Generation: 1
- Reason: Success
- Status: True
- Type: Resolved
- Last Transition Time: 2024-03-15T15:04:13Z
- Message: installed from "quay.io/operatorhubio/camel-k@sha256:d2b74c43ec8f9294450c9dcf2057be328d0998bb924ad036db489af79d1b39c3"
- Observed Generation: 1
- Reason: Success
- Status: True
- Type: Installed
- Installed Bundle Resource: quay.io/operatorhubio/camel-k@sha256:d2b74c43ec8f9294450c9dcf2057be328d0998bb924ad036db489af79d1b39c3
- Resolved Bundle Resource: quay.io/operatorhubio/camel-k@sha256:d2b74c43ec8f9294450c9dcf2057be328d0998bb924ad036db489af79d1b39c3
- Events:
+ Conditions:
+ Last Transition Time: 2024-10-03T16:02:41Z
+ Message:
+ Observed Generation: 2
+ Reason: Deprecated
+ Status: False
+ Type: Deprecated
+ Last Transition Time: 2024-10-03T16:02:41Z
+ Message:
+ Observed Generation: 2
+ Reason: Deprecated
+ Status: False
+ Type: PackageDeprecated
+ Last Transition Time: 2024-10-03T16:02:41Z
+ Message:
+ Observed Generation: 2
+ Reason: Deprecated
+ Status: False
+ Type: ChannelDeprecated
+ Last Transition Time: 2024-10-03T16:02:41Z
+ Message:
+ Observed Generation: 2
+ Reason: Deprecated
+ Status: False
+ Type: BundleDeprecated
+ Last Transition Time: 2024-10-03T16:02:43Z
+ Message: Installed bundle quay.io/operatorhubio/argocd-operator@sha256:d538c45a813b38ef0e44f40d279dc2653f97ca901fb660da5d7fe499d51ad3b3 successfully
+ Observed Generation: 2
+ Reason: Succeeded
+ Status: True
+ Type: Installed
+ Last Transition Time: 2024-10-03T16:02:43Z
+ Message: desired state reached
+ Observed Generation: 2
+ Reason: Succeeded
+ Status: False
+ Type: Progressing
+ Install:
+ Bundle:
+ Name: argocd-operator.v0.6.0
+ Version: 0.6.0
+ Events:
```
diff --git a/docs/tutorials/upgrade-extension.md b/docs/tutorials/upgrade-extension.md
index e55a53f96..ea0a20344 100644
--- a/docs/tutorials/upgrade-extension.md
+++ b/docs/tutorials/upgrade-extension.md
@@ -92,83 +92,73 @@ spec:
??? success
``` text title="Example output"
- Name: argocd
- Namespace:
- Labels: olm.operatorframework.io/owner-kind=ClusterExtension
- olm.operatorframework.io/owner-name=argocd
- Annotations:
- API Version: olm.operatorframework.io/v1alpha1
- Kind: ClusterExtension
- Metadata:
- Creation Timestamp: 2024-09-06T13:38:38Z
- Finalizers:
- olm.operatorframework.io/cleanup-unpack-cache
- olm.operatorframework.io/cleanup-contentmanager-cache
- Generation: 5
- Resource Version: 21167
- UID: 5abdf57d-aedc-45d4-ba0d-a86e785fd34a
- Spec:
- Install:
- Namespace: argocd
- Service Account:
- Name: argocd-installer
- Source:
- Catalog:
- Package Name: argocd-operator
- Selector:
- Upgrade Constraint Policy: Enforce
- Version: 0.6.0
- Source Type: Catalog
- Status:
- Conditions:
- Last Transition Time: 2024-09-06T13:38:38Z
- Message:
- Observed Generation: 5
- Reason: Deprecated
- Status: False
- Type: Deprecated
- Last Transition Time: 2024-09-06T13:38:38Z
- Message:
- Observed Generation: 5
- Reason: Deprecated
- Status: False
- Type: PackageDeprecated
- Last Transition Time: 2024-09-06T13:38:38Z
- Message:
- Observed Generation: 5
- Reason: Deprecated
- Status: False
- Type: ChannelDeprecated
- Last Transition Time: 2024-09-06T13:38:38Z
- Message:
- Observed Generation: 5
- Reason: Deprecated
- Status: False
- Type: BundleDeprecated
- Last Transition Time: 2024-09-06T13:40:14Z
- Message: resolved to "quay.io/operatorhubio/argocd-operator@sha256:d538c45a813b38ef0e44f40d279dc2653f97ca901fb660da5d7fe499d51ad3b3"
- Observed Generation: 5
- Reason: Success
- Status: True
- Type: Resolved
- Last Transition Time: 2024-09-06T13:38:38Z
- Message: unpack successful:
- Observed Generation: 5
- Reason: UnpackSuccess
- Status: True
- Type: Unpacked
- Last Transition Time: 2024-09-06T13:40:31Z
- Message: Installed bundle quay.io/operatorhubio/argocd-operator@sha256:d538c45a813b38ef0e44f40d279dc2653f97ca901fb660da5d7fe499d51ad3b3 successfully
- Observed Generation: 5
- Reason: Success
- Status: True
- Type: Installed
- Install:
- Bundle:
- Name: argocd-operator.v0.6.0
- Version: 0.6.0
- Resolution:
- Bundle:
- Name: argocd-operator.v0.6.0
- Version: 0.6.0
+ apiVersion: olm.operatorframework.io/v1alpha1
+ kind: ClusterExtension
+ metadata:
+ annotations:
+ kubectl.kubernetes.io/last-applied-configuration: |
+ {"apiVersion":"olm.operatorframework.io/v1alpha1","kind":"ClusterExtension","metadata":{"annotations":{},"name":"argocd"},"spec":{"install":{"namespace":"argocd","serviceAccount":{"name":"argocd-installer"}},"source":{"catalog":{"packageName":"argocd-operator","version":"0.6.0"},"sourceType":"Catalog"}}}
+ creationTimestamp: "2024-10-03T16:02:40Z"
+ finalizers:
+ - olm.operatorframework.io/cleanup-unpack-cache
+ - olm.operatorframework.io/cleanup-contentmanager-cache
+ generation: 2
+ name: argocd
+ resourceVersion: "1174"
+ uid: 0fcaf3f5-d142-4c7e-8d88-c88a549f7764
+ spec:
+ install:
+ namespace: argocd
+ serviceAccount:
+ name: argocd-installer
+ source:
+ catalog:
+ packageName: argocd-operator
+ selector: {}
+ upgradeConstraintPolicy: CatalogProvided
+ version: 0.6.0
+ sourceType: Catalog
+ status:
+ conditions:
+ - lastTransitionTime: "2024-10-03T16:02:41Z"
+ message: ""
+ observedGeneration: 2
+ reason: Deprecated
+ status: "False"
+ type: Deprecated
+ - lastTransitionTime: "2024-10-03T16:02:41Z"
+ message: ""
+ observedGeneration: 2
+ reason: Deprecated
+ status: "False"
+ type: PackageDeprecated
+ - lastTransitionTime: "2024-10-03T16:02:41Z"
+ message: ""
+ observedGeneration: 2
+ reason: Deprecated
+ status: "False"
+ type: ChannelDeprecated
+ - lastTransitionTime: "2024-10-03T16:02:41Z"
+ message: ""
+ observedGeneration: 2
+ reason: Deprecated
+ status: "False"
+ type: BundleDeprecated
+ - lastTransitionTime: "2024-10-03T16:02:43Z"
+ message: Installed bundle quay.io/operatorhubio/argocd-operator@sha256:d538c45a813b38ef0e44f40d279dc2653f97ca901fb660da5d7fe499d51ad3b3
+ successfully
+ observedGeneration: 2
+ reason: Succeeded
+ status: "True"
+ type: Installed
+ - lastTransitionTime: "2024-10-03T16:02:43Z"
+ message: desired state reached
+ observedGeneration: 2
+ reason: Succeeded
+ status: "False"
+ type: Progressing
+ install:
+ bundle:
+ name: argocd-operator.v0.6.0
+ version: 0.6.0
```
diff --git a/internal/controllers/clusterextension_controller_test.go b/internal/controllers/clusterextension_controller_test.go
index 23f81363c..8f7331384 100644
--- a/internal/controllers/clusterextension_controller_test.go
+++ b/internal/controllers/clusterextension_controller_test.go
@@ -421,7 +421,7 @@ func TestClusterExtensionApplierFailsWithBundleInstalled(t *testing.T) {
installedCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
require.NotNil(t, installedCond)
require.Equal(t, metav1.ConditionTrue, installedCond.Status)
- require.Equal(t, ocv1alpha1.ReasonSuccess, installedCond.Reason)
+ require.Equal(t, ocv1alpha1.ReasonSucceeded, installedCond.Reason)
t.Log("By checking the expected progressing conditions")
progressingCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
@@ -505,7 +505,7 @@ func TestClusterExtensionManagerFailed(t *testing.T) {
installedCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
require.NotNil(t, installedCond)
require.Equal(t, metav1.ConditionTrue, installedCond.Status)
- require.Equal(t, ocv1alpha1.ReasonSuccess, installedCond.Reason)
+ require.Equal(t, ocv1alpha1.ReasonSucceeded, installedCond.Reason)
t.Log("By checking the expected progressing conditions")
progressingCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
@@ -591,7 +591,7 @@ func TestClusterExtensionManagedContentCacheWatchFail(t *testing.T) {
installedCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
require.NotNil(t, installedCond)
require.Equal(t, metav1.ConditionTrue, installedCond.Status)
- require.Equal(t, ocv1alpha1.ReasonSuccess, installedCond.Reason)
+ require.Equal(t, ocv1alpha1.ReasonSucceeded, installedCond.Reason)
t.Log("By checking the expected progressing conditions")
progressingCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
@@ -674,13 +674,13 @@ func TestClusterExtensionInstallationSucceeds(t *testing.T) {
installedCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
require.NotNil(t, installedCond)
require.Equal(t, metav1.ConditionTrue, installedCond.Status)
- require.Equal(t, ocv1alpha1.ReasonSuccess, installedCond.Reason)
+ require.Equal(t, ocv1alpha1.ReasonSucceeded, installedCond.Reason)
t.Log("By checking the expected progressing conditions")
progressingCond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
require.NotNil(t, progressingCond)
require.Equal(t, metav1.ConditionFalse, progressingCond.Status)
- require.Equal(t, ocv1alpha1.ReasonSuccess, progressingCond.Reason)
+ require.Equal(t, ocv1alpha1.ReasonSucceeded, progressingCond.Reason)
require.NoError(t, cl.DeleteAllOf(ctx, &ocv1alpha1.ClusterExtension{}))
}
diff --git a/internal/controllers/common_controller.go b/internal/controllers/common_controller.go
index 8210f3999..d04cd0a01 100644
--- a/internal/controllers/common_controller.go
+++ b/internal/controllers/common_controller.go
@@ -31,7 +31,7 @@ func setInstalledStatusConditionSuccess(ext *ocv1alpha1.ClusterExtension, messag
apimeta.SetStatusCondition(&ext.Status.Conditions, metav1.Condition{
Type: ocv1alpha1.TypeInstalled,
Status: metav1.ConditionTrue,
- Reason: ocv1alpha1.ReasonSuccess,
+ Reason: ocv1alpha1.ReasonSucceeded,
Message: message,
ObservedGeneration: ext.GetGeneration(),
})
@@ -56,7 +56,7 @@ func setStatusProgressing(ext *ocv1alpha1.ClusterExtension, err error) {
progressingCond := metav1.Condition{
Type: ocv1alpha1.TypeProgressing,
Status: metav1.ConditionFalse,
- Reason: ocv1alpha1.ReasonSuccess,
+ Reason: ocv1alpha1.ReasonSucceeded,
Message: "desired state reached",
ObservedGeneration: ext.GetGeneration(),
}
diff --git a/internal/controllers/common_controller_test.go b/internal/controllers/common_controller_test.go
index 8715464d6..8f703fc6e 100644
--- a/internal/controllers/common_controller_test.go
+++ b/internal/controllers/common_controller_test.go
@@ -28,7 +28,7 @@ func TestSetStatusProgressing(t *testing.T) {
expected: metav1.Condition{
Type: ocv1alpha1.TypeProgressing,
Status: metav1.ConditionFalse,
- Reason: ocv1alpha1.ReasonSuccess,
+ Reason: ocv1alpha1.ReasonSucceeded,
Message: "desired state reached",
},
},
diff --git a/test/e2e/cluster_extension_install_test.go b/test/e2e/cluster_extension_install_test.go
index 18ade9677..ed514a70b 100644
--- a/test/e2e/cluster_extension_install_test.go
+++ b/test/e2e/cluster_extension_install_test.go
@@ -276,7 +276,7 @@ func TestClusterExtensionInstallRegistry(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
@@ -286,7 +286,7 @@ func TestClusterExtensionInstallRegistry(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionTrue, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
assert.Contains(ct, cond.Message, "Installed bundle")
assert.NotEmpty(ct, clusterExtension.Status.Install.Bundle)
}
@@ -377,7 +377,7 @@ func TestClusterExtensionBlockInstallNonSuccessorVersion(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
@@ -433,7 +433,7 @@ func TestClusterExtensionForceInstallNonSuccessorVersion(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
@@ -449,7 +449,7 @@ func TestClusterExtensionForceInstallNonSuccessorVersion(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
}
@@ -484,7 +484,7 @@ func TestClusterExtensionInstallSuccessorVersion(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
@@ -499,7 +499,7 @@ func TestClusterExtensionInstallSuccessorVersion(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
}
@@ -544,7 +544,7 @@ func TestClusterExtensionInstallReResolvesWhenCatalogIsPatched(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
@@ -568,7 +568,7 @@ func TestClusterExtensionInstallReResolvesWhenCatalogIsPatched(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
}
@@ -625,7 +625,7 @@ func TestClusterExtensionInstallReResolvesWhenNewCatalog(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
@@ -649,7 +649,7 @@ func TestClusterExtensionInstallReResolvesWhenNewCatalog(t *testing.T) {
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
}
@@ -688,7 +688,7 @@ func TestClusterExtensionInstallReResolvesWhenManagedContentChanged(t *testing.T
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionTrue, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
assert.Contains(ct, cond.Message, "Installed bundle")
}
}, pollDuration, pollInterval)
@@ -786,7 +786,7 @@ func TestClusterExtensionRecoversFromInitialInstallFailedWhenFailureFixed(t *tes
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeInstalled)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionTrue, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
assert.Contains(ct, cond.Message, "Installed bundle")
assert.NotEmpty(ct, clusterExtension.Status.Install)
}
@@ -798,7 +798,7 @@ func TestClusterExtensionRecoversFromInitialInstallFailedWhenFailureFixed(t *tes
cond := apimeta.FindStatusCondition(clusterExtension.Status.Conditions, ocv1alpha1.TypeProgressing)
if assert.NotNil(ct, cond) {
assert.Equal(ct, metav1.ConditionFalse, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}
}, pollDuration, pollInterval)
}
diff --git a/test/extension-developer-e2e/extension_developer_test.go b/test/extension-developer-e2e/extension_developer_test.go
index 2db90b674..4a11a7530 100644
--- a/test/extension-developer-e2e/extension_developer_test.go
+++ b/test/extension-developer-e2e/extension_developer_test.go
@@ -209,7 +209,7 @@ func TestExtensionDeveloper(t *testing.T) {
return
}
assert.Equal(ct, metav1.ConditionTrue, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
}, 2*time.Minute, time.Second)
require.NoError(t, c.Delete(context.Background(), catalog))
require.NoError(t, c.Delete(context.Background(), clusterExtension))
diff --git a/test/upgrade-e2e/post_upgrade_test.go b/test/upgrade-e2e/post_upgrade_test.go
index f893b8e2a..78f7284a8 100644
--- a/test/upgrade-e2e/post_upgrade_test.go
+++ b/test/upgrade-e2e/post_upgrade_test.go
@@ -84,7 +84,7 @@ func TestClusterExtensionAfterOLMUpgrade(t *testing.T) {
return
}
assert.Equal(ct, metav1.ConditionTrue, cond.Status)
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
assert.Contains(ct, cond.Message, "Installed bundle")
if assert.NotNil(ct, clusterExtension.Status.Install) {
assert.NotEmpty(ct, clusterExtension.Status.Install.Bundle.Version)
@@ -105,7 +105,7 @@ func TestClusterExtensionAfterOLMUpgrade(t *testing.T) {
if !assert.NotNil(ct, cond) {
return
}
- assert.Equal(ct, ocv1alpha1.ReasonSuccess, cond.Reason)
+ assert.Equal(ct, ocv1alpha1.ReasonSucceeded, cond.Reason)
assert.Contains(ct, cond.Message, "Installed bundle")
assert.Equal(ct, ocv1alpha1.BundleMetadata{Name: "prometheus-operator.1.0.1", Version: "1.0.1"}, clusterExtension.Status.Install.Bundle)
assert.NotEqual(ct, previousVersion, clusterExtension.Status.Install.Bundle.Version)