Skip to content
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

ETag Double Quote Inconsistency #1038

Open
subliminal-nm opened this issue Mar 21, 2024 · 1 comment
Open

ETag Double Quote Inconsistency #1038

subliminal-nm opened this issue Mar 21, 2024 · 1 comment
Assignees

Comments

@subliminal-nm
Copy link

There seems to be an inconsistency in the way that ETags are handled. Calls to GetObjectAsync and StatObjectAsync strip the double quotes -

ObjectStat.cs

                case "etag":
                    objInfo.ETag = paramValue.Replace("\"", string.Empty, StringComparison.OrdinalIgnoreCase);
                    break;

while PutObjectAsync does not strip the quotes -

PutObjectResponse.cs

           if (parameter.Key.Equals("ETag", StringComparison.OrdinalIgnoreCase))
           {
               Etag = parameter.Value;
               break;
           }

The format of an ETag should be consistent across the whole API.

Also, there is an inconsistency in the spelling. PutObjectResponse uses a lower case 't' in Etag, while ObjectStat uses an upper case 'T' in ETag.

@ebozduman
Copy link
Collaborator

The refactoring task currently I am working on will also address this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants