Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What happen when I set Quiet to true in Amazon S3 for anabling Quiet Mode in deleteObjects() method?

I'm working with Amazon S3 in Node.js and I want to delete one or more files from a bucket. I want to know what happen when I set Quiet parameter to true.

var params = {
  Bucket: 'STRING_VALUE', /* required */
  Delete: { /* required */
    Objects: [ /* required */
      {
        Key: 'STRING_VALUE', /* required */
        VersionId: 'STRING_VALUE'
      },
      /* more items */
    ],
    Quiet: true || false
  },
  MFA: 'STRING_VALUE'
};
s3.deleteObjects(params, function(err, data) {
  if (err) console.log(err, err.stack); // an error occurred
  else     console.log(data);           // successful response
});

I appreciate any help.

like image 369
Ragnar Avatar asked Dec 22 '14 22:12

Ragnar


1 Answers

As from Amazon Docs: Quiet Mode:

Toggles between Quiet and Verbose mode for the operation. If set to true (Quiet mode), the response includes only those keys for objects on which the delete operation failed.

like image 191
Kashif Zaidi Avatar answered Sep 28 '22 16:09

Kashif Zaidi