Azure Blob 儲存體至 Google Cloud 儲存體 (GCS) 傳輸運算子

Google Cloud 儲存體 (GCS) 用於儲存來自各種應用程式的大量資料。Azure Blob 儲存體 也是如此。本頁說明如何將資料從 Azure Blob 儲存體傳輸到 GCS。

先決條件任務

若要使用這些運算子,您必須執行幾項操作

將資料從 Azure Blob 儲存體傳輸到 Google Cloud 儲存體

運算子將資料從 Azure Blob 儲存體傳輸到 Google Cloud 儲存體中指定的儲存桶

使用 AzureBlobStorageToGCSOperator 將資料從 Azure Blob 儲存體傳輸到 Google Cloud 儲存體。

範例用法

tests/system/google/cloud/azure/example_azure_blob_to_gcs.py[原始碼]

    transfer_files_to_gcs = AzureBlobStorageToGCSOperator(
        task_id="transfer_files_to_gcs",
        # azure args
        container_name=AZURE_CONTAINER_NAME,
        blob_name=BLOB_NAME,
        # GCP args
        bucket_name=GCP_BUCKET_NAME,
        object_name=GCP_OBJECT_NAME,
        filename=GCP_BUCKET_FILE_PATH,
        gzip=False,
        impersonation_chain=None,
    )

此條目是否有幫助?