Skip to content

Commit

Permalink
Merge pull request #67 from m00g3n/fix-cluster-not-found
Browse files Browse the repository at this point in the history
Change the logic of reconciliation on unrecoverable error
  • Loading branch information
kyma-bot authored Nov 17, 2023
2 parents b2d2b4d + ff864a5 commit c8fa74a
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions internal/controller/gardener_cluster_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,11 @@ func (controller *GardenerClusterController) Reconcile(ctx context.Context, req
kubeconfigStatus, err := controller.handleKubeconfig(ctx, &cluster, lastSyncTime)
if err != nil {
_ = controller.persistStatusChange(ctx, &cluster)
// if a claster was not found in gardener,
// CRD should not be rereconciled
if k8serrors.IsNotFound(err) {
err = nil
}
return controller.resultWithoutRequeue(), err
}

Expand Down

0 comments on commit c8fa74a

Please sign in to comment.