Adding some error handling and gzippedOnly  s3 option