简体   繁体   English

S3 ManagedUpload 在 aws javascript sdk v3 中等效?

[英]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},
});

More information here .更多信息在这里

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用浏览器的 aws-sdk V3 (javascript) 跟踪上传到 S3 的进度 - How to track upload progress to S3 using aws-sdk V3 for browser (javascript) 使用适用于 JavaScript 的 AWS 开发工具包 v3 完成多部分上传到 S3 的 XML 错误 - XML error completing a multi-part upload to S3 with AWS SDK for JavaScript v3 AWS SDK for PHP v3中是否存在与NoSuchKeyException等效的内容? - Is there an equivalent to NoSuchKeyException in AWS SDK for PHP v3? 适用于 Node.js 的 AWS S3 SDK V3 - GetObjectCommand v/s getSignedUrl - AWS S3 SDK V3 for Node.js - GetObjectCommand v/s getSignedUrl aws-sdk v3 中 aws-sdk v2 中 Aws::S3::Presigner#presigned_request 的替代方案 - Alternative for Aws::S3::Presigner#presigned_request in aws-sdk v3 in aws-sdk v2 使用 AWS-SDK JS V3 实例化 S3 Class 时出现“缺少凭据”错误 - 'Credential is missing' Error On Instantiating S3 Class Using AWS-SDK JS V3 如何使用 aws-sdk v3 从 S3 保存文件 - How to save file from S3 using aws-sdk v3 Aws SDK:集成 AWS v3 时出现 CredentialsProviderError Javascript SDK - Aws SDK: CredentialsProviderError while integrating AWS v3 Javascript SDK 适用于s3的AWS SDK v2 - AWS SDK v2 for s3 S3 为使用 aws-sdk v3 预签名的 PutObject 命令 url 提供 SignatureDoesNotMatch 错误 - S3 gives SignatureDoesNotMatch error for PutObject command pre-signed url using aws-sdk v3
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM