2
python googleクラウドストレージのバッチ機能の使用方法に関する例は見つかりません。それが存在するのを見たhere。Google Cloud StorageのPythonクライアントでのバッチリクエスト
具体的な例が気に入っています。私は与えられた接頭辞を持つブロブの束を削除したいとしましょう。私は
from google.cloud import storage
storage_client = storage.Client()
bucket = storage_client.get_bucket('my_bucket_name')
blobs_to_delete = bucket.list_blobs(prefix="my/prefix/here")
# how do I delete the blobs in blobs_to_delete in a single batch?
# bonus: if I have more than 100 blobs to delete, handle the limitation
# that a batch can only handle 100 operations