We are using GCS (google cloud storage) and I am wondering if the methods described in https://cloud.google.com/appengine/docs/standard/python/googlecloudstorageclient/read-write-to-cloud-storage using open/close lock the file from other things accessing it during the operations?
I am a novice and currently the first method I found is using the download and upload as string functions in import cloudstorage as gcs
like...
current_details = json.loads(device_blob.download_as_string().decode('utf-8'))
LOGGER.info(current_details)
current_details.update(details)
device_blob.upload_from_string(json.dumps(current_details))
But it is obvious here that between the download and upload calls something else could modify the file.
So if the import cloudstorage as gcs is the way to go, please let me know.
Thank you!
cloudstorage as gcsis the way to go"? - Nahuel Varela