-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Log HTTP response writer message instead an error #5405
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Log HTTP response writer message instead an error #5405
Conversation
We cannot throw an additional HTTP error if the response write fails, because it already sets the http error code internally. This resulted in an "http: superfluous response.WriteHeader call" error. To mitigate the issue, we now only log the error. Signed-off-by: Sascha Grunert <[email protected]>
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: saschagrunert The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@cri-o/cri-o-maintainers PTAL |
Codecov Report
@@ Coverage Diff @@
## main #5405 +/- ##
=======================================
Coverage 43.72% 43.73%
=======================================
Files 118 118
Lines 11752 11751 -1
=======================================
Hits 5139 5139
+ Misses 6125 6124 -1
Partials 488 488 |
|
/test integration_crun |
|
LGTM |
|
@saschagrunert: The following tests failed, say
Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
|
/lgtm |
|
/retest-required Please review the full test history for this PR and help us cut down flakes. |
2 similar comments
|
/retest-required Please review the full test history for this PR and help us cut down flakes. |
|
/retest-required Please review the full test history for this PR and help us cut down flakes. |
What type of PR is this?
/kind bug
What this PR does / why we need it:
We cannot throw an additional HTTP error if the response write fails,
because it already sets the http error code internally. This resulted in
an "http: superfluous response.WriteHeader call" error. To mitigate the
issue, we now only log the error.
Which issue(s) this PR fixes:
Refers to https://bugzilla.redhat.com/show_bug.cgi?id=2006654
Special notes for your reviewer:
None
Does this PR introduce a user-facing change?