[PR #187] [MERGED] rewriteObject: don't ignore metadata #417

Closed
opened 2026-03-03 12:29:54 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/fsouza/fake-gcs-server/pull/187
Author: @pschultz
Created: 2/27/2020
Status: Merged
Merged: 2/28/2020
Merged by: @fsouza

Base: masterHead: rewrite-with-metadata


📝 Commits (1)

  • 517fbad upload, rewrite: read metadata from request body

📊 Changes

4 files changed (+47 additions, -15 deletions)

View changed files

📝 fakestorage/object.go (+19 -8)
📝 fakestorage/object_test.go (+11 -2)
📝 fakestorage/upload.go (+9 -4)
📝 fakestorage/upload_test.go (+8 -1)

📄 Description

Server.rewriteObject erroneously copies metadata from the source object, which isn't how GCS behaves. Metadata is provided in the request body, just like when creating objects.

Also, multipartUpload ignored user-defined metadata.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/fsouza/fake-gcs-server/pull/187 **Author:** [@pschultz](https://github.com/pschultz) **Created:** 2/27/2020 **Status:** ✅ Merged **Merged:** 2/28/2020 **Merged by:** [@fsouza](https://github.com/fsouza) **Base:** `master` ← **Head:** `rewrite-with-metadata` --- ### 📝 Commits (1) - [`517fbad`](https://github.com/fsouza/fake-gcs-server/commit/517fbad8069fbbc9834bbec019a43aa6f6d6ec96) upload, rewrite: read metadata from request body ### 📊 Changes **4 files changed** (+47 additions, -15 deletions) <details> <summary>View changed files</summary> 📝 `fakestorage/object.go` (+19 -8) 📝 `fakestorage/object_test.go` (+11 -2) 📝 `fakestorage/upload.go` (+9 -4) 📝 `fakestorage/upload_test.go` (+8 -1) </details> ### 📄 Description Server.rewriteObject erroneously copies metadata from the source object, which isn't how GCS behaves. Metadata is provided in the request body, just like when creating objects. Also, multipartUpload ignored user-defined metadata. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 12:29:54 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/fake-gcs-server#417
No description provided.