StatefulSet: Don't touch Pods if DeletionTimestamp is set.

This commit is contained in:
Anthony Yeh
2017-02-23 11:44:09 -08:00
parent 61e7d1ebf1
commit f269e78ebc
2 changed files with 69 additions and 0 deletions

View File

@@ -111,6 +111,12 @@ func (ssc *defaultStatefulSetControl) UpdateStatefulSet(set *apps.StatefulSet, p
}
}
// If the StatefulSet is being deleted, don't do anything other than updating
// status.
if set.DeletionTimestamp != nil {
return nil
}
// Examine each replica with respect to its ordinal
for i := range replicas {
// delete and recreate failed pods