Skip to content

Commit

Permalink
Revert fault tolerance check to only check availability (#1514)
Browse files Browse the repository at this point in the history
* Revert fault tolerance check to only check availability
  • Loading branch information
johscheuer authored Feb 24, 2023
1 parent 02137e0 commit 9a8cc41
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions controllers/bounce_processes.go
Original file line number Diff line number Diff line change
Expand Up @@ -255,9 +255,13 @@ func getAddressesForUpgrade(logger logr.Logger, r *FoundationDBClusterReconciler
return nil, &requeue{curError: err}
}

if !internal.HasDesiredFaultToleranceFromStatus(logger, databaseStatus, cluster) {
r.Recorder.Event(cluster, corev1.EventTypeNormal, "UpgradeRequeued", "Database is unavailable or doesn't have expected fault tolerance")
return nil, &requeue{message: "Deferring upgrade until database is available or expected fault tolerance is met"}
// We don't want to check for fault tolerance here to make sure the operator is able to restart processes if some
// processes where restarted before the operator issued the cluster wide restart. For version incompatible upgrades
// that would mean that the processes restarted earlier are not part of the cluster anymore leading to a fault tolerance
// drop.
if !databaseStatus.Client.DatabaseStatus.Available {
r.Recorder.Event(cluster, corev1.EventTypeNormal, "UpgradeRequeued", "Database is unavailable")
return nil, &requeue{message: "Deferring upgrade until database is available"}
}

notReadyProcesses := make([]string, 0)
Expand Down

0 comments on commit 9a8cc41

Please sign in to comment.