gaul / s3proxy

Access other storage backends via the S3 API
Apache License 2.0
1.79k stars 233 forks source link

Add middleware to replace user metadata #702

Closed gaul closed 3 weeks ago

gaul commented 1 month ago

This is useful when keys and values must conform to some subset of values, e.g., Azure's C# identifiers. Fixes #466.

gaul commented 1 month ago

Does single-character replacement suffice? Or would something more involved like regexes address more use cases?

atsai1220 commented 1 month ago

Could be another option. For example, s3proxy.user-metadata-replacer-blobstore-regex=true/false. Thoughts?

gaul commented 1 month ago

Do you have a specific use case for more complicated replacements? I won't add technical complexity just for fun.

atsai1220 commented 1 month ago

I'm happy with a straightforward string match and replacement.