Gaufrette
Gaufrette copied to clipboard
Reduced Redundancy Storage
Using AwsS3, is it possible to write the objects to reduced redundancy storage?
Here's the docs: http://docs.aws.amazon.com/AmazonS3/latest/dev/SetStoClsOfObjUploaded.html
There's also the issue of the 405 when the file may no longer exist because it's reduced redundancy. Does Gaufrette throw an exception?
Figured it out, it just needs meta data using the File object.
However can there be a new tagged release? The last one was 3 months old.
Solution looks like this:
//setup the file object
$snapshot_file = new File($snapshot_name, $this->filesystem);
//write the snapshot data, and potentially overwrite it
$s3_query = $snapshot_file->setContent($snapshot_data, [
'ContentType' => 'application/x-bzip2',
'StorageClass' => 'REDUCED_REDUNDANCY'
]);