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

Common Headers support for object #1122

Closed
vlakas opened this issue Sep 14, 2018 · 2 comments
Closed

Common Headers support for object #1122

vlakas opened this issue Sep 14, 2018 · 2 comments
Assignees
Labels

Comments

@vlakas
Copy link

vlakas commented Sep 14, 2018

Here is list of common HTTP headers that AWS S3 supports for requests:
https://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectPUT.html#RESTObjectPUT-requests

Example:

 $ s3cmd -c ~/s3/aws put --add-header=Content-Encoding:gzip -P put test1.txt s3://example-file/
 $ curl -D - -o /dev/null http://example-file.s3.amazonaws.com/test1.txt
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0HTTP/1.1 200 OK
x-amz-id-2: kU7YcmwSeCFdGlJZrG+hHKlBSFvXJf6b276Q8VG2KAnTMAsU/+0IOisIzBfI0El0rGuDJe1m3Pg=
x-amz-request-id: 58A72E35B3C57A4A
Date: Fri, 14 Sep 2018 11:06:55 GMT
Last-Modified: Fri, 14 Sep 2018 11:06:40 GMT
ETag: "ba1f2511fc30423bdbb183fe33f3dd0f"
x-amz-meta-s3cmd-attrs: atime:1536920342/ctime:1536920295/gid:1000/gname:vlakas/md5:ba1f2511fc30423bdbb183fe33f3dd0f/mode:33188/mtime:1536920295/uid:1000/uname:vlakas
Content-Encoding: gzip
Accept-Ranges: bytes
Content-Type: text/plain
Content-Length: 4
Server: AmazonS3

Pay attention on Content-Encoding header.

The same thing with leofs:

 $ s3cmd -c ~/s3/leofs -P --add-header=Content-Encoding:gzip put test1.txt s3://testpub
 $ curl -D - -o /dev/null http://testpub.leofs_host/test1.txt
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0HTTP/1.1 200 OK
Date: Fri, 14 Sep 2018 11:11:42 GMT
Content-Length: 4
x-amz-meta-s3cmd-attrs: atime:1536920342/ctime:1536920295/gid:1000/gname:vlakas/md5:ba1f2511fc30423bdbb183fe33f3dd0f/mode:33188/mtime:1536920295/uid:1000/uname:vlakas
Server: LeoFS
Content-Type: text/plain
ETag: "ba1f2511fc30423bdbb183fe33f3dd0f"
Last-Modified: Fri, 14 Sep 2018 11:11:30 GMT

Do LeoFS support such headers for object?

With custom request headers x-aws-meta-* there is no issues.

@mocchira mocchira self-assigned this Sep 15, 2018
@mocchira
Copy link
Member

@vlakas

Do LeoFS support such headers for object?

Still not yet, however we have the issue to support gzip encoding here: #420 so please vote(pick your reaction) on the issue if you do want the feature as we tend to prioritize the issue which many users want.

@mocchira
Copy link
Member

As I commented on the above, this issue is duplicated with #420 so I'll close this one. Now two users have voted on #420 so we will re-consider its priority.

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

No branches or pull requests

2 participants