Commit 9a7bfe7f authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #36642 from kargakis/log-already-exists

Automatic merge from submit-queue Do not emit event for AlreadyExists errors Fixes https://github.com/kubernetes/kubernetes/issues/36598 also reduced the clutter of events since the AlreadyExists error is a common error (may be a slow rs cache or a fast resync of the deployment that causes it apart from hash collisions) @kubernetes/deployment
parents dbb4def4 9afe2c3a
...@@ -359,7 +359,8 @@ func (dc *DeploymentController) getNewReplicaSet(deployment *extensions.Deployme ...@@ -359,7 +359,8 @@ func (dc *DeploymentController) getNewReplicaSet(deployment *extensions.Deployme
// We may end up hitting this due to a slow cache or a fast resync of the deployment. // We may end up hitting this due to a slow cache or a fast resync of the deployment.
// TODO: Restore once https://github.com/kubernetes/kubernetes/issues/29735 is fixed // TODO: Restore once https://github.com/kubernetes/kubernetes/issues/29735 is fixed
// ie. we start using a new hashing algorithm. // ie. we start using a new hashing algorithm.
// case errors.IsAlreadyExists(err): case errors.IsAlreadyExists(err):
return nil, err
// return dc.rsLister.ReplicaSets(namespace).Get(newRS.Name) // return dc.rsLister.ReplicaSets(namespace).Get(newRS.Name)
case err != nil: case err != nil:
msg := fmt.Sprintf("Failed to create new replica set %q: %v", newRS.Name, err) msg := fmt.Sprintf("Failed to create new replica set %q: %v", newRS.Name, err)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment