Skip to content

feat: add tags copy for mirror #5137

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

Merged
merged 3 commits into from
Feb 13, 2025

Conversation

jiuker
Copy link
Contributor

@jiuker jiuker commented Feb 13, 2025

feat: add taggs copy for mirror

Community Contribution License

All community contributions in this pull request are licensed to the project maintainers
under the terms of the Apache 2 license.
By creating this pull request I represent that I have the right to license the
contributions to the project maintainers under the Apache 2 license.

Description

Motivation and Context

How to test this PR?

one shell for

mc alias set minio9000 http://192.168.101.100:9000 minioadmin minioadmin
mc alias set minio9001 http://192.168.101.100:9001 minioadmin minioadmin
mc.exe mirror --watch --overwrite --remove minio9000 minio9001

another shell

mc cp token minio9000/sourcebucket01 --tags "E:C=789&ABC:d=123"
mc cp issue.sh minio9000/sourcebucket01 --tags "A=C&B=D"

mc stat minio9000/sourcebucket01/token
mc stat minio9001/sourcebucket01/token
mc stat minio9000/sourcebucket01/issue.sh
mc stat minio9001/sourcebucket01/issue.sh
D:\workspace\go\src\mc\stage\issue.sh:  216 B / 216 B [==================================================================================================================================================] 19.81 KiB/s 0sName      : token
Date      : 2025-02-13 16:23:22 CST
Size      : 199 B
ETag      : 200296977455005a8e9f60f881748ac9
Type      : file
Metadata  :
  Content-Type       : application/octet-stream
  X-Amz-Tagging-Count: 2

Name      : token
Date      : 2025-02-13 16:23:22 CST
Size      : 199 B
ETag      : 200296977455005a8e9f60f881748ac9
Type      : file
Metadata  :
  X-Amz-Tagging-Count       : 2
  X-Amz-Meta-Mm-Source-Mtime: 2025-02-13T08:23:22.334Z
  Content-Type              : application/octet-stream

Name      : issue.sh
Date      : 2025-02-13 16:23:22 CST
Size      : 216 B
ETag      : 280ffe317a7b222153800a84ff735f7b
Type      : file
Metadata  :
  Content-Type       : application/x-sh
  X-Amz-Tagging-Count: 2

Name      : issue.sh
Date      : 2025-02-13 16:23:22 CST
Size      : 216 B
ETag      : 280ffe317a7b222153800a84ff735f7b
Type      : file
Metadata  :
  X-Amz-Meta-Mm-Source-Mtime: 2025-02-13T08:23:22.396Z
  X-Amz-Tagging-Count       : 2
  Content-Type              : application/x-sh

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Optimization (provides speedup with no functional changes)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • Fixes a regression (If yes, please add commit-id or PR # here)
  • Unit tests added/updated
  • Internal documentation updated
  • Create a documentation update request here

feat: add taggs copy for mirror
@harshavardhana harshavardhana changed the title feat: add taggs copy for mirror feat: add tags copy for mirror Feb 13, 2025
jiuker and others added 2 commits February 13, 2025 16:26
Co-authored-by: Harshavardhana <harsha@minio.io>
Co-authored-by: Harshavardhana <harsha@minio.io>
@harshavardhana
Copy link
Member

Can you update the tests here to expect tags ?

@jiuker
Copy link
Contributor Author

jiuker commented Feb 13, 2025

image
image
image
image
@harshavardhana ^^

@harshavardhana
Copy link
Member

Can you update the tests here to expect tags ?

@jiuker I meant add tests in cmd/suite_test.go, will merge the PR.

@harshavardhana harshavardhana merged commit 147e8f5 into minio:master Feb 13, 2025
5 checks passed
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

Successfully merging this pull request may close these issues.

3 participants