RC/RS: Don't requeue on error inside sync function.

Returning an error from the sync function already triggers a requeue
in processNextWorkItem().
This commit is contained in:
Anthony Yeh
2017-02-25 13:09:15 -08:00
parent f54a5c9728
commit db6665251a
4 changed files with 55 additions and 29 deletions

View File

@@ -554,9 +554,6 @@ func (rsc *ReplicaSetController) syncReplicaSet(key string) error {
cm := controller.NewPodControllerRefManager(rsc.podControl, rs, selector, controllerKind)
filteredPods, err = cm.ClaimPods(pods)
if err != nil {
// Something went wrong with adoption or release.
// Requeue and try again so we don't leave orphans sitting around.
rsc.queue.Add(key)
return err
}