mirror of
https://github.com/fsouza/fake-gcs-server.git
synced 2026-04-26 06:05:54 +03:00
[PR #1524] [MERGED] Additional object response attributes #1575
Labels
No labels
bug
compatibility-issue
docker
documentation
enhancement
help wanted
needs information
pull-request
question
stale
unfortunate
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/fake-gcs-server#1575
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/fsouza/fake-gcs-server/pull/1524
Author: @manuteleco
Created: 3/8/2024
Status: ✅ Merged
Merged: 3/18/2024
Merged by: @fsouza
Base:
main← Head:additional_object_response_attributes📝 Commits (3)
013aee0Additional object response attributes97841f3fixup! Additional object response attributes6c65141fixup! Additional object response attributes📊 Changes
4 files changed (+32 additions, -15 deletions)
View changed files
📝
fakestorage/object.go(+5 -5)📝
fakestorage/object_test.go(+9 -0)📝
fakestorage/response.go(+13 -5)📝
fakestorage/upload.go(+5 -5)📄 Description
Some GCS client libraries (like this one), are quite strict when it comes to the set of attributes they expect to find in the response. If any of those attributes is missing, they fail to deserialize the response.
Here we introduce three new attributes in the Object response:
SelfLinkMediaLinkMetagenerationSelfLinkcannot be tested using the Go GCS client library, as it is not included in theObjectAttrsstruct.For the
Metagenerationwe just hardcode the value"1", considering that we are not keeping track of it internally and"1"happens to be the correct value most of the times anyway.Edited: I believe this PR fixes #758, which I only noticed after the fact.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.