Commit 6ea64034 authored by Yunhua Koglin's avatar Yunhua Koglin
Browse files

update

parent 49ff885e
......@@ -214,9 +214,12 @@ class AwsStorage(BlobStorageBase):
aws_access_key_id=self._access_key,
aws_secret_access_key=self._secret_key,
aws_session_token=self._session_token
)
obj = s3_client.get_object(Bucket=self._bucket_name, Key=object_name)
return obj['Body'].read()
)
outfile = io.BytesIO()
s3_client.download_fileobj(bucket, object_name, outfile)
outfile.seek(0)
return outfile
# return obj['Body'].read()
async def download_metadata(self, tenant: Tenant, object_name: str,
*, auth: Optional = None, timeout: int = 10, ** kwargs) -> Blob:
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment