Skip to content

Commit

Permalink
Revert "Use LabelsAndGenerationPredicate for ToolchainClusterCache co…
Browse files Browse the repository at this point in the history
…ntroller (#437)" (#438)

This reverts commit 463b623.
  • Loading branch information
rajivnathan authored Dec 11, 2024
1 parent 463b623 commit 1282865
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (

toolchainv1alpha1 "github.com/codeready-toolchain/api/api/v1alpha1"
"github.com/codeready-toolchain/toolchain-common/pkg/cluster"
commonpredicates "github.com/codeready-toolchain/toolchain-common/pkg/predicate"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/runtime"
ctrl "sigs.k8s.io/controller-runtime"
Expand All @@ -32,7 +31,7 @@ func NewReconciler(mgr manager.Manager, namespace string, timeout time.Duration)
// SetupWithManager sets up the controller with the Manager.
func (r *Reconciler) SetupWithManager(mgr ctrl.Manager) error {
return ctrl.NewControllerManagedBy(mgr).
For(&toolchainv1alpha1.ToolchainCluster{}, builder.WithPredicates(namespacePredicate{namespace: r.namespace}, commonpredicates.LabelsAndGenerationPredicate{})).
For(&toolchainv1alpha1.ToolchainCluster{}, builder.WithPredicates(namespacePredicate{namespace: r.namespace})).
Complete(r)
}

Expand Down

0 comments on commit 1282865

Please sign in to comment.