diff --git a/pkg/actuators/machine/actuator.go b/pkg/actuators/machine/actuator.go index 9d5cd68c1c..b84503c5be 100644 --- a/pkg/actuators/machine/actuator.go +++ b/pkg/actuators/machine/actuator.go @@ -432,6 +432,11 @@ func (a *Actuator) Update(context context.Context, cluster *clusterv1.Cluster, m // Parent controller should prevent this from ever happening by calling Exists and then Create, // but instance could be deleted between the two calls. if existingLen == 0 { + if machine.Spec.ProviderID != nil && (machine.Status.LastUpdated == nil || machine.Status.LastUpdated.Add(requeueAfterSeconds*time.Second).After(time.Now())) { + glog.Infof("%s: Possible eventual-consistency discrepancy; returning an error to requeue", machine.Name) + return &clustererror.RequeueAfterError{RequeueAfter: requeueAfterSeconds * time.Second} + } + glog.Warningf("%s: attempted to update machine but no instances found", machine.Name) a.handleMachineError(machine, mapierrors.UpdateMachine("no instance found, reason unknown"), updateEventAction)