Alibaba Cloud Copy

Alibaba Cloud Copy

Certified

Copy an object within OSS

Copies an object to another key, optionally in another bucket of the same region and account, and can delete the source afterwards to move it. The copy is a single request, so it is limited to objects of at most 1 GB, which is checked before copying. If the source cannot be deleted after a successful copy, the task fails with a message saying the copy exists.

yaml
type: io.kestra.plugin.alibaba.oss.Copy

Copy an object, then remove the source to move it

yaml
id: oss_copy
namespace: company.team

tasks:
  - id: move
    type: io.kestra.plugin.alibaba.oss.Copy
    accessKeyId: "{{ secret('ALIBABA_ACCESS_KEY_ID') }}"
    accessKeySecret: "{{ secret('ALIBABA_ACCESS_KEY_SECRET') }}"
    region: cn-hangzhou
    bucket: my-bucket
    key: landing/data.csv
    destinationKey: archive/data.csv
    delete: true
Properties

AccessKey ID

The AccessKey ID used to authenticate against Alibaba Cloud.

AccessKey secret

The AccessKey secret paired with the AccessKey ID.

Bucket

The name of the OSS bucket.

Destination object key

The key of the copy. It must differ from the source when the bucket is the same.

Source object key

The key of the object to copy, in bucket.

Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.

Definitions
assetFailureBehaviorstring
Possible Values
IGNOREFAILWARN

Asset failure behavior

Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.

enableAutobooleanstring

Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.

inputsarray

The assets consumed as inputs.

id*string
Min length1
typestring
outputs

The assets produced as outputs.

id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*string
Min length1

Custom asset type

descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
Defaultfalse

Delete the source

Delete the source object once it is copied, which moves it.

Destination bucket

The bucket to copy to. Defaults to bucket.

Endpoint override

Custom http or https endpoint URL. When set, it takes precedence over the endpoint derived from region.

Defaultfalse

Path-style access

Address buckets as <endpoint>/<bucket> instead of <bucket>.<endpoint>. Useful with custom endpoints such as a local emulator.

Region

The Alibaba Cloud region ID, for example cn-hangzhou. The service endpoint is derived from it unless endpointOverride is set.

Security token

Optional Security Token Service (STS) token, required when using temporary credentials.

Bucket of the copy

ETag of the copy

Key of the copy