resumable_upload_v2_initiate_multipart_upload

package
v7.25.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 17, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

使用 Multipart Upload 方式上传数据前,必须先调用 API 来获取一个全局唯一的 UploadId,后续的块数据通过 uploadPart API 上传,整个文件完成 completeMultipartUpload API,已经上传块的删除 abortMultipartUpload API 都依赖该 UploadId

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NewMultipartUpload

type NewMultipartUpload = Response

返回本次 MultipartUpload 相关信息

type Request

type Request struct {
	BucketName string           // 存储空间名称
	ObjectName *string          // 对象名称
	UpToken    uptoken.Provider // 上传凭证,如果为空,则使用 HTTPClientOptions 中的 UpToken
}

调用 API 所用的请求

type Response

type Response struct {
	UploadId  string // 初始化文件生成的 id
	ExpiredAt int64  // UploadId 的过期时间 UNIX 时间戳,过期之后 UploadId 不可用
}

获取 API 所用的响应

func (*Response) MarshalJSON

func (j *Response) MarshalJSON() ([]byte, error)

func (*Response) UnmarshalJSON

func (j *Response) UnmarshalJSON(data []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL