controller: Clean up status.InstanceManagerName for detaching error instance only
If instance handler directly cleans up the field for the error
process with spec.DesireStatus running, then there is no way
to find the correct instance manager and clean up the
corresponding error process for the subsequent detachment.
@@ -288,8 +288,10 @@ func (h *InstanceHandler) ReconcileInstanceState(obj interface{}, spec *types.In
}
}
}
+ if spec.DesireState == types.InstanceStateStopped {
status.InstanceManagerName = ""
}
+ }
return nil
}
