Skip to content

Commit

Permalink
Merge pull request #6441 from smarterclayton/hide_already_exists_error
Browse files Browse the repository at this point in the history
Do not log "event already exists" errors
  • Loading branch information
rjnagal committed Apr 6, 2015
2 parents 6b51476 + aee73d6 commit fe735d3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/client/record/event.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,11 @@ func recordEvent(sink EventSink, event *api.Event, updateExistingEvent bool) boo
glog.Errorf("Unable to construct event '%#v': '%v' (will not retry!)", event, err)
return true
case *errors.StatusError:
glog.Errorf("Server rejected event '%#v': '%v' (will not retry!)", event, err)
if errors.IsAlreadyExists(err) {
glog.V(5).Infof("Server rejected event '%#v': '%v' (will not retry!)", event, err)
} else {
glog.Errorf("Server rejected event '%#v': '%v' (will not retry!)", event, err)
}
return true
case *errors.UnexpectedObjectError:
// We don't expect this; it implies the server's response didn't match a
Expand Down

0 comments on commit fe735d3

Please sign in to comment.