airflow.providers.amazon.aws.transfers.azure_blob_to_s3

Module Contents

Classes

AzureBlobStorageToS3Operator

Operator transfers data from Azure Blob Storage to specified bucket in Amazon S3.

class airflow.providers.amazon.aws.transfers.azure_blob_to_s3.AzureBlobStorageToS3Operator(*, wasb_conn_id='wasb_default', container_name, prefix=None, delimiter='', aws_conn_id='aws_default', dest_s3_key, dest_verify=None, dest_s3_extra_args=None, replace=False, s3_acl_policy=None, wasb_extra_args=None, s3_extra_args=None, **kwargs)[source]

Bases: airflow.models.BaseOperator

Operator transfers data from Azure Blob Storage to specified bucket in Amazon S3.

See also

For more information on how to use this operator, take a look at the guide: Transfer Data from Azure Blob Storage to Google Cloud Storage

Parameters
  • wasb_conn_id (str) – Reference to the wasb connection.

  • container_name (str) – Name of the container

  • prefix (str | None) – Prefix string which filters objects whose name begin with this prefix. (templated)

  • delimiter (str) – The delimiter by which you want to filter the objects. (templated) For e.g to lists the CSV files from in a directory in GCS you would use delimiter=’.csv’.

  • aws_conn_id (str | None) – Connection id of the S3 connection to use

  • dest_s3_key (str) – The base S3 key to be used to store the files. (templated)

  • dest_verify (str | bool | None) –

    Whether or not to verify SSL certificates for S3 connection. By default SSL certificates are verified. You can provide the following values:

    • False: do not validate SSL certificates. SSL will still be used

      (unless use_ssl is False), but SSL certificates will not be verified.

    • path/to/cert/bundle.pem: A filename of the CA cert bundle to uses.

      You can specify this argument if you want to use a different CA cert bundle than the one used by botocore.

  • dest_s3_extra_args (dict | None) – Extra arguments that may be passed to the download/upload operations.

  • replace (bool) – Whether or not to verify the existence of the files in the destination bucket. By default is set to False If set to True, will upload all the files replacing the existing ones in the destination bucket. If set to False, will upload only the files that are in the origin but not in the destination bucket.

  • s3_acl_policy (str | None) – Optional The string to specify the canned ACL policy for the object to be uploaded in S3

  • wasb_extra_kargs – kwargs to pass to WasbHook

  • s3_extra_kargs – kwargs to pass to S3Hook

template_fields: Sequence[str] = ('container_name', 'prefix', 'delimiter', 'dest_s3_key')[source]
execute(context)[source]

Derive when creating an operator.

Context is the same dictionary used as when rendering jinja templates.

Refer to get_template_context for more context.

Was this entry helpful?