Automattic / knox

S3 Lib
MIT License
1.74k stars 285 forks source link

Ignore putStream content-length requirement when transfer-encoding is chunked #323

Open ccorcos opened 7 years ago

ccorcos commented 7 years ago

https://github.com/Automattic/knox/issues/322 @TooTallNate @rauchg

Now the following code works:

const request = require("request")

request.get(url)
    .on("response", (res) => {
        const req = client.putStream(res, "some/path", res.headers, function (err, res) {
            console.log(err, req.url)
        })
    })
ccorcos commented 7 years ago

Wait a second... I'm getting a 501 Not Implemented response...

ccorcos commented 7 years ago

Looks like this might be a better option for me: https://github.com/nathanpeck/s3-upload-stream

devpascoe commented 7 years ago

@ccorcos i tried that s3-upload-stream package too on a chunked stream i wanted to upload directly to s3 and its callback never ... called back. Tried all the libraries. How has no one run into this issue before?