Project

General

Profile

Actions

Bug #23434

open

RGWs report canceled PUT requests as 500s instead of 408s

Added by Bryan Stillwell about 6 years ago. Updated almost 6 years ago.

Status:
New
Priority:
Normal
Assignee:
Target version:
-
% Done:

0%

Source:
Community (user)
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

While troubleshooting some issues that were being recorded in the civetweb access logs on 10.2.10, I noticed that S3 PUT requests that are canceled (for example when you hit ctrl-c during the upload) are showing up in the logs as 500s (internal server error). I compared this to how nginx handles partial uploads and it uses either a 408 (request timeout) or as a 400 (bad request). I think these are more descriptive of the actual problem and would like to see radosgw use them as well.

Actions #1

Updated by Matt Benjamin about 6 years ago

The rationale for returning 500 in a variety of cases, is to ensure they are retried by S3 clients. That might apply in a case where RGW is certain that the client abandoned the request, but returning 4XX to a client could have semantic effects.

https://docs.aws.amazon.com/AmazonS3/latest/dev/ErrorBestPractices.html

"""
Retry InternalErrors

Internal errors are errors that occur within the Amazon S3 environment.

Requests that receive an InternalError response might not have processed. For example, if a PUT request returns InternalError, a subsequent GET might retrieve the old value or the updated value.

If Amazon S3 returns an InternalError response, retry the request.
"""

Actions #2

Updated by Greg Farnum about 6 years ago

  • Project changed from Ceph to rgw
Actions #3

Updated by Orit Wasserman almost 6 years ago

  • Assignee set to Matt Benjamin
Actions

Also available in: Atom PDF