Skip to content

Add Buffer and Stream support for S3 #3

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

Closed
tracker1 opened this issue Dec 5, 2012 · 11 comments
Closed

Add Buffer and Stream support for S3 #3

tracker1 opened this issue Dec 5, 2012 · 11 comments
Labels
feature-request A feature should be added or improved.
Milestone

Comments

@tracker1
Copy link

tracker1 commented Dec 5, 2012

Would be nice to be able to pass a buffer, or stream in addition to a base-64 encoded string. Since these are the typical interfaces for dealing with binary data in Node.js

@reconbot
Copy link

reconbot commented Dec 5, 2012

+1

1 similar comment
@Rob-ot
Copy link

Rob-ot commented Dec 5, 2012

+1

@trevorrowe
Copy link
Contributor

This is a known omission at this point. We will definitely be adding proper support for working with binary data.

@tracker1
Copy link
Author

Absolutely appreciated... I know supporting a Buffer should be simple enough, and wrapping a stream interface could be a bit more of a pain.

@dominicbarnes
Copy link

+1

@deanmao
Copy link

deanmao commented Dec 27, 2012

Ok cool. so it has nothing to do with my code then... I naively assumed I could download files with their s3 library. But there's some weird utf-conversion issue.

@vanb
Copy link

vanb commented Dec 27, 2012

+1

@deanmao
Copy link

deanmao commented Dec 28, 2012

I hacked in buffer support in my fork, only because I really needed it, but the code may not be very DRY:

deanmao@994aaec

However, it works... at least I can now download files from S3 and write to disk without having a weird utf-8 conversion screwing up all the bytes.

I could do a pull request, but maybe the library authors prefer the body-as-buffer to be set via a method parameter option instead?

Actually, shouldn't the body always be a buffer until we know we need to convert it to a string? I feel like that whole method could just be done a lot better...

@BharatMeda
Copy link

@trevorrowe Thank you. Looking forward for this feature.

@BharatMeda
Copy link

Would you be updating the package manager with the latest changes? Thanks in advance.

@srchase srchase added feature-request A feature should be added or improved. and removed enhancement labels Jan 4, 2019
@lock
Copy link

lock bot commented Sep 29, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

@lock lock bot locked as resolved and limited conversation to collaborators Sep 29, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature-request A feature should be added or improved.
Projects
None yet
Development

No branches or pull requests

10 participants