[英]S3 ManagedUpload equivalent in aws javascript sdk v3?
In the older version of javascript I was using managedupload function for uploading big files to s3, which will do the queueing and manage multiparting of files.在旧版本的 javascript 中,我使用 managedupload function 将大文件上传到 s3,它将进行排队和管理文件的多部分。 But in V3 this function is not anywhere in documentation, is that removed?但是在 V3 中,这个 function 不在文档中的任何地方,是否已删除? or is there any alternatives?还是有其他选择? Please help...请帮忙...
In V3 the high level abstractions are moved to functionality specific lib
packages while the client packages offer a one to one mapping of the low level public apis.在 V3 中,高级抽象被移至功能特定的lib
包,而客户端包提供低级公共 api 的一对一映射。
For S3
the client is in @aws-sdk/client-s3
and the high level operations are in @aws-sdk/lib-storage
packages respectively.对于S3
,客户端位于@aws-sdk/client-s3
中,高级操作分别位于@aws-sdk/lib-storage
包中。
Sample upload code for a managed upload would look like the following托管上传的示例上传代码如下所示
const { S3Client } = require("@aws-sdk/client-s3");
const { Upload } = require("@aws-sdk/lib-storage");
const multipartUpload = new Upload({
client: new S3Client({}),
params: {Bucket: 'bucket', Key: 'key', Body: stream},
});
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.