MCPcopy
hub / github.com/scality/cloudserver / putObject

Function putObject

tests/sur/quota.js:85–98  ·  view source on GitHub ↗
(bucket, key, size, cb)

Source from the content-addressed store, hash-verified

83}
84
85function putObject(bucket, key, size, cb) {
86 return s3Client.send(new PutObjectCommand({
87 Bucket: bucket,
88 Key: key,
89 Body: Buffer.alloc(size),
90 }))
91 .then(data => {
92 if (!s3Config.isQuotaInflightEnabled()) {
93 mockScuba.incrementBytesForBucket(bucket, size);
94 }
95 return cb(null, data);
96 })
97 .catch(cb);
98}
99
100function putObjectWithCustomHeader(bucket, key, size, vID, cb) {
101 const params = {

Callers 1

quota.jsFile · 0.70

Calls 3

sendMethod · 0.80

Tested by

no test coverage detected