aws-sdk-js: Error: Non-file stream objects are not supported with SigV4 when using s3.uploadPart()
I get the following error:
Non-file stream objects are not supported with SigV4
when passing a FileStream
to s3.uploadPart()
.
Oddly I don’t get the error if I swap s3.uploadPart()
for s3.upload()
- this leads me to believe my object is a valid file stream.
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 17 (5 by maintainers)
Commits related to this issue
- Tag release v2.4.2 References: #1034, #965 — committed to aws/aws-sdk-js by chrisradek 8 years ago
@PsyTae With version 2.4.0, the S3 client was updated to use Sigv4 by default. It’s still possible to use Sigv2 by specifying you want to use that when instantiating your client:
This issue should only occur when using
signatureVersion: v4
due to how the body is signed. Can you share how your input stream is created?The stream is created by
Busboy
https://github.com/mscdex/busboy and I just pass it as is to s3Note that if I build the incoming busboy stream in memory before handing it to
s3.uploadPart()
it works fine:The stream is created by
Busboy
https://github.com/mscdex/busboy and I just pass it as is to s3 - but that’s just to slow and memory intensive.