@aws-amplify/storage 5.6.3 → 5.6.4-api-v6.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/AwsClients/S3/abortMultipartUpload.d.ts +21 -0
- package/lib/AwsClients/S3/abortMultipartUpload.js +85 -0
- package/lib/AwsClients/S3/base.d.ts +54 -0
- package/lib/AwsClients/S3/base.js +75 -0
- package/lib/AwsClients/S3/completeMultipartUpload.d.ts +20 -0
- package/lib/AwsClients/S3/completeMultipartUpload.js +162 -0
- package/lib/AwsClients/S3/copyObject.d.ts +24 -0
- package/lib/AwsClients/S3/copyObject.js +98 -0
- package/lib/AwsClients/S3/createMultipartUpload.d.ts +21 -0
- package/lib/AwsClients/S3/createMultipartUpload.js +95 -0
- package/lib/AwsClients/S3/deleteObject.d.ts +20 -0
- package/lib/AwsClients/S3/deleteObject.js +86 -0
- package/lib/AwsClients/S3/getObject.d.ts +27 -0
- package/lib/AwsClients/S3/getObject.js +216 -0
- package/lib/AwsClients/S3/headObject.d.ts +20 -0
- package/lib/AwsClients/S3/headObject.js +96 -0
- package/lib/AwsClients/S3/index.d.ts +13 -0
- package/lib/AwsClients/S3/index.js +30 -0
- package/lib/AwsClients/S3/index.native.d.ts +14 -0
- package/lib/AwsClients/S3/index.native.js +31 -0
- package/lib/AwsClients/S3/listObjectsV2.d.ts +20 -0
- package/lib/AwsClients/S3/listObjectsV2.js +146 -0
- package/lib/AwsClients/S3/listParts.d.ts +20 -0
- package/lib/AwsClients/S3/listParts.js +110 -0
- package/lib/AwsClients/S3/putObject.d.ts +23 -0
- package/lib/AwsClients/S3/putObject.js +93 -0
- package/lib/AwsClients/S3/runtime/base64/index.browser.d.ts +2 -0
- package/lib/AwsClients/S3/runtime/base64/index.browser.js +20 -0
- package/lib/AwsClients/S3/runtime/base64/index.native.d.ts +2 -0
- package/lib/AwsClients/S3/runtime/base64/index.native.js +17 -0
- package/lib/AwsClients/S3/runtime/constants.d.ts +9 -0
- package/lib/AwsClients/S3/runtime/constants.js +14 -0
- package/lib/AwsClients/S3/runtime/contentSha256middleware.d.ts +9 -0
- package/lib/AwsClients/S3/runtime/contentSha256middleware.js +70 -0
- package/lib/AwsClients/S3/runtime/index.browser.d.ts +5 -0
- package/lib/AwsClients/S3/runtime/index.browser.js +20 -0
- package/lib/AwsClients/S3/runtime/index.d.ts +5 -0
- package/lib/AwsClients/S3/runtime/index.js +21 -0
- package/lib/AwsClients/S3/runtime/index.native.d.ts +5 -0
- package/lib/AwsClients/S3/runtime/index.native.js +20 -0
- package/lib/AwsClients/S3/runtime/s3TransferHandler/fetch.d.ts +8 -0
- package/lib/AwsClients/S3/runtime/s3TransferHandler/fetch.js +15 -0
- package/lib/AwsClients/S3/runtime/s3TransferHandler/xhr.d.ts +8 -0
- package/lib/AwsClients/S3/runtime/s3TransferHandler/xhr.js +21 -0
- package/lib/AwsClients/S3/runtime/xhrTransferHandler.d.ts +22 -0
- package/lib/AwsClients/S3/runtime/xhrTransferHandler.js +201 -0
- package/lib/AwsClients/S3/runtime/xmlParser/dom.d.ts +8 -0
- package/lib/AwsClients/S3/runtime/xmlParser/dom.js +92 -0
- package/lib/AwsClients/S3/runtime/xmlParser/pureJs.d.ts +10 -0
- package/lib/AwsClients/S3/runtime/xmlParser/pureJs.js +57 -0
- package/lib/AwsClients/S3/types.d.ts +2857 -0
- package/lib/AwsClients/S3/types.js +4 -0
- package/lib/AwsClients/S3/uploadPart.d.ts +20 -0
- package/lib/AwsClients/S3/uploadPart.js +96 -0
- package/lib/AwsClients/S3/utils/deserializeHelpers.d.ts +78 -0
- package/lib/AwsClients/S3/utils/deserializeHelpers.js +153 -0
- package/lib/AwsClients/S3/utils/index.d.ts +5 -0
- package/lib/AwsClients/S3/utils/index.js +30 -0
- package/lib/AwsClients/S3/utils/parsePayload.d.ts +3 -0
- package/lib/AwsClients/S3/utils/parsePayload.js +96 -0
- package/lib/AwsClients/S3/utils/serializeHelpers.d.ts +42 -0
- package/lib/AwsClients/S3/utils/serializeHelpers.js +183 -0
- package/lib/Storage.d.ts +5 -5
- package/lib/Storage.js +60 -31
- package/lib/common/S3ClientUtils.d.ts +24 -15
- package/lib/common/S3ClientUtils.js +83 -95
- package/lib/common/StorageConstants.d.ts +0 -1
- package/lib/common/StorageConstants.js +3 -2
- package/lib/common/StorageErrorStrings.js +3 -1
- package/lib/common/StorageUtils.js +12 -6
- package/lib/index.js +19 -4
- package/lib/providers/AWSS3Provider.d.ts +4 -8
- package/lib/providers/AWSS3Provider.js +210 -139
- package/lib/providers/AWSS3ProviderManagedUpload.d.ts +7 -7
- package/lib/providers/AWSS3ProviderManagedUpload.js +184 -98
- package/lib/providers/AWSS3UploadTask.d.ts +8 -8
- package/lib/providers/AWSS3UploadTask.js +226 -129
- package/lib/providers/index.js +4 -2
- package/lib/tsconfig.tsbuildinfo +1 -0
- package/lib/types/AWSS3Provider.d.ts +62 -62
- package/lib/types/AWSS3Provider.js +0 -1
- package/lib/types/Provider.d.ts +1 -1
- package/lib/types/Provider.js +2 -1
- package/lib/types/Storage.d.ts +23 -23
- package/lib/types/Storage.js +0 -1
- package/lib/types/index.js +17 -1
- package/lib-esm/AwsClients/S3/abortMultipartUpload.d.ts +21 -0
- package/lib-esm/AwsClients/S3/abortMultipartUpload.js +82 -0
- package/lib-esm/AwsClients/S3/base.d.ts +54 -0
- package/lib-esm/AwsClients/S3/base.js +71 -0
- package/lib-esm/AwsClients/S3/completeMultipartUpload.d.ts +20 -0
- package/lib-esm/AwsClients/S3/completeMultipartUpload.js +159 -0
- package/lib-esm/AwsClients/S3/copyObject.d.ts +24 -0
- package/lib-esm/AwsClients/S3/copyObject.js +95 -0
- package/lib-esm/AwsClients/S3/createMultipartUpload.d.ts +21 -0
- package/lib-esm/AwsClients/S3/createMultipartUpload.js +92 -0
- package/lib-esm/AwsClients/S3/deleteObject.d.ts +20 -0
- package/lib-esm/AwsClients/S3/deleteObject.js +83 -0
- package/lib-esm/AwsClients/S3/getObject.d.ts +27 -0
- package/lib-esm/AwsClients/S3/getObject.js +212 -0
- package/lib-esm/AwsClients/S3/headObject.d.ts +20 -0
- package/lib-esm/AwsClients/S3/headObject.js +93 -0
- package/lib-esm/AwsClients/S3/index.d.ts +13 -0
- package/lib-esm/AwsClients/S3/index.js +14 -0
- package/lib-esm/AwsClients/S3/index.native.d.ts +14 -0
- package/lib-esm/AwsClients/S3/index.native.js +15 -0
- package/lib-esm/AwsClients/S3/listObjectsV2.d.ts +20 -0
- package/lib-esm/AwsClients/S3/listObjectsV2.js +143 -0
- package/lib-esm/AwsClients/S3/listParts.d.ts +20 -0
- package/lib-esm/AwsClients/S3/listParts.js +107 -0
- package/lib-esm/AwsClients/S3/putObject.d.ts +23 -0
- package/lib-esm/AwsClients/S3/putObject.js +90 -0
- package/lib-esm/AwsClients/S3/runtime/base64/index.browser.d.ts +2 -0
- package/lib-esm/AwsClients/S3/runtime/base64/index.browser.js +15 -0
- package/lib-esm/AwsClients/S3/runtime/base64/index.native.d.ts +2 -0
- package/lib-esm/AwsClients/S3/runtime/base64/index.native.js +12 -0
- package/lib-esm/AwsClients/S3/runtime/constants.d.ts +9 -0
- package/lib-esm/AwsClients/S3/runtime/constants.js +11 -0
- package/lib-esm/AwsClients/S3/runtime/contentSha256middleware.d.ts +9 -0
- package/lib-esm/AwsClients/S3/runtime/contentSha256middleware.js +66 -0
- package/lib-esm/AwsClients/S3/runtime/index.browser.d.ts +5 -0
- package/lib-esm/AwsClients/S3/runtime/index.browser.js +8 -0
- package/lib-esm/AwsClients/S3/runtime/index.d.ts +5 -0
- package/lib-esm/AwsClients/S3/runtime/index.js +9 -0
- package/lib-esm/AwsClients/S3/runtime/index.native.d.ts +5 -0
- package/lib-esm/AwsClients/S3/runtime/index.native.js +8 -0
- package/lib-esm/AwsClients/S3/runtime/s3TransferHandler/fetch.d.ts +8 -0
- package/lib-esm/AwsClients/S3/runtime/s3TransferHandler/fetch.js +12 -0
- package/lib-esm/AwsClients/S3/runtime/s3TransferHandler/xhr.d.ts +8 -0
- package/lib-esm/AwsClients/S3/runtime/s3TransferHandler/xhr.js +18 -0
- package/lib-esm/AwsClients/S3/runtime/xhrTransferHandler.d.ts +22 -0
- package/lib-esm/AwsClients/S3/runtime/xhrTransferHandler.js +196 -0
- package/lib-esm/AwsClients/S3/runtime/xmlParser/dom.d.ts +8 -0
- package/lib-esm/AwsClients/S3/runtime/xmlParser/dom.js +89 -0
- package/lib-esm/AwsClients/S3/runtime/xmlParser/pureJs.d.ts +10 -0
- package/lib-esm/AwsClients/S3/runtime/xmlParser/pureJs.js +54 -0
- package/lib-esm/AwsClients/S3/types.d.ts +2857 -0
- package/lib-esm/AwsClients/S3/types.js +3 -0
- package/lib-esm/AwsClients/S3/uploadPart.d.ts +20 -0
- package/lib-esm/AwsClients/S3/uploadPart.js +93 -0
- package/lib-esm/AwsClients/S3/utils/deserializeHelpers.d.ts +78 -0
- package/lib-esm/AwsClients/S3/utils/deserializeHelpers.js +144 -0
- package/lib-esm/AwsClients/S3/utils/index.d.ts +5 -0
- package/lib-esm/AwsClients/S3/utils/index.js +7 -0
- package/lib-esm/AwsClients/S3/utils/parsePayload.d.ts +3 -0
- package/lib-esm/AwsClients/S3/utils/parsePayload.js +91 -0
- package/lib-esm/AwsClients/S3/utils/serializeHelpers.d.ts +42 -0
- package/lib-esm/AwsClients/S3/utils/serializeHelpers.js +176 -0
- package/lib-esm/Storage.d.ts +5 -5
- package/lib-esm/Storage.js +53 -25
- package/lib-esm/common/S3ClientUtils.d.ts +24 -15
- package/lib-esm/common/S3ClientUtils.js +76 -93
- package/lib-esm/common/StorageConstants.d.ts +0 -1
- package/lib-esm/common/StorageConstants.js +2 -2
- package/lib-esm/common/StorageErrorStrings.js +2 -1
- package/lib-esm/common/StorageUtils.js +2 -1
- package/lib-esm/index.js +1 -1
- package/lib-esm/providers/AWSS3Provider.d.ts +4 -8
- package/lib-esm/providers/AWSS3Provider.js +162 -115
- package/lib-esm/providers/AWSS3ProviderManagedUpload.d.ts +7 -7
- package/lib-esm/providers/AWSS3ProviderManagedUpload.js +172 -87
- package/lib-esm/providers/AWSS3UploadTask.d.ts +8 -8
- package/lib-esm/providers/AWSS3UploadTask.js +202 -106
- package/lib-esm/providers/index.js +2 -1
- package/lib-esm/tsconfig.tsbuildinfo +1 -0
- package/lib-esm/types/AWSS3Provider.d.ts +62 -62
- package/lib-esm/types/AWSS3Provider.js +1 -1
- package/lib-esm/types/Provider.d.ts +1 -1
- package/lib-esm/types/Provider.js +3 -1
- package/lib-esm/types/Storage.d.ts +23 -23
- package/lib-esm/types/Storage.js +1 -1
- package/lib-esm/types/index.js +3 -1
- package/package.json +21 -26
- package/src/AwsClients/S3/abortMultipartUpload.ts +62 -0
- package/src/AwsClients/S3/base.ts +109 -0
- package/src/AwsClients/S3/completeMultipartUpload.ts +154 -0
- package/src/AwsClients/S3/copyObject.ts +90 -0
- package/src/AwsClients/S3/createMultipartUpload.ts +75 -0
- package/src/AwsClients/S3/deleteObject.ts +69 -0
- package/src/AwsClients/S3/getObject.ts +173 -0
- package/src/AwsClients/S3/headObject.ts +91 -0
- package/src/AwsClients/S3/index.native.ts +42 -0
- package/src/AwsClients/S3/index.ts +41 -0
- package/src/AwsClients/S3/listObjectsV2.ts +130 -0
- package/src/AwsClients/S3/listParts.ts +97 -0
- package/src/AwsClients/S3/putObject.ts +94 -0
- package/src/AwsClients/S3/runtime/base64/index.browser.ts +21 -0
- package/src/AwsClients/S3/runtime/base64/index.native.ts +16 -0
- package/src/AwsClients/S3/runtime/constants.ts +16 -0
- package/src/AwsClients/S3/runtime/contentSha256middleware.ts +29 -0
- package/src/AwsClients/S3/runtime/index.browser.ts +14 -0
- package/src/AwsClients/S3/runtime/index.native.ts +14 -0
- package/src/AwsClients/S3/runtime/index.ts +15 -0
- package/src/AwsClients/S3/runtime/s3TransferHandler/fetch.ts +23 -0
- package/src/AwsClients/S3/runtime/s3TransferHandler/xhr.ts +35 -0
- package/src/AwsClients/S3/runtime/xhrTransferHandler.ts +254 -0
- package/src/AwsClients/S3/runtime/xmlParser/dom.ts +92 -0
- package/src/AwsClients/S3/runtime/xmlParser/pureJs.ts +55 -0
- package/src/AwsClients/S3/types.ts +2877 -0
- package/src/AwsClients/S3/uploadPart.ts +83 -0
- package/src/AwsClients/S3/utils/deserializeHelpers.ts +136 -0
- package/src/AwsClients/S3/utils/index.ts +27 -0
- package/src/AwsClients/S3/utils/parsePayload.ts +45 -0
- package/src/AwsClients/S3/utils/serializeHelpers.ts +112 -0
- package/src/Storage.ts +30 -27
- package/src/common/S3ClientUtils.ts +57 -113
- package/src/common/StorageConstants.ts +2 -2
- package/src/common/StorageErrorStrings.ts +2 -0
- package/src/common/StorageUtils.ts +2 -0
- package/src/providers/AWSS3Provider.ts +80 -100
- package/src/providers/AWSS3ProviderManagedUpload.ts +56 -63
- package/src/providers/AWSS3UploadTask.ts +86 -87
- package/src/providers/index.ts +2 -0
- package/src/types/AWSS3Provider.ts +55 -49
- package/src/types/Provider.ts +7 -2
- package/lib/.tsbuildinfo +0 -3
- package/lib/Storage.js.map +0 -1
- package/lib/common/S3ClientUtils.js.map +0 -1
- package/lib/common/StorageConstants.js.map +0 -1
- package/lib/common/StorageErrorStrings.js.map +0 -1
- package/lib/common/StorageUtils.js.map +0 -1
- package/lib/index.js.map +0 -1
- package/lib/providers/AWSS3Provider.js.map +0 -1
- package/lib/providers/AWSS3ProviderManagedUpload.js.map +0 -1
- package/lib/providers/AWSS3UploadTask.js.map +0 -1
- package/lib/providers/axios-http-handler.d.ts +0 -40
- package/lib/providers/axios-http-handler.js +0 -193
- package/lib/providers/axios-http-handler.js.map +0 -1
- package/lib/providers/index.js.map +0 -1
- package/lib/types/AWSS3Provider.js.map +0 -1
- package/lib/types/Provider.js.map +0 -1
- package/lib/types/Storage.js.map +0 -1
- package/lib/types/index.js.map +0 -1
- package/lib-esm/.tsbuildinfo +0 -3
- package/lib-esm/Storage.js.map +0 -1
- package/lib-esm/common/S3ClientUtils.js.map +0 -1
- package/lib-esm/common/StorageConstants.js.map +0 -1
- package/lib-esm/common/StorageErrorStrings.js.map +0 -1
- package/lib-esm/common/StorageUtils.js.map +0 -1
- package/lib-esm/index.js.map +0 -1
- package/lib-esm/providers/AWSS3Provider.js.map +0 -1
- package/lib-esm/providers/AWSS3ProviderManagedUpload.js.map +0 -1
- package/lib-esm/providers/AWSS3UploadTask.js.map +0 -1
- package/lib-esm/providers/axios-http-handler.d.ts +0 -40
- package/lib-esm/providers/axios-http-handler.js +0 -191
- package/lib-esm/providers/axios-http-handler.js.map +0 -1
- package/lib-esm/providers/index.js.map +0 -1
- package/lib-esm/types/AWSS3Provider.js.map +0 -1
- package/lib-esm/types/Provider.js.map +0 -1
- package/lib-esm/types/Storage.js.map +0 -1
- package/lib-esm/types/index.js.map +0 -1
- package/src/providers/axios-http-handler.ts +0 -242
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __assign = (this && this.__assign) || function () {
|
|
3
|
+
__assign = Object.assign || function(t) {
|
|
4
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
5
|
+
s = arguments[i];
|
|
6
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
7
|
+
t[p] = s[p];
|
|
8
|
+
}
|
|
9
|
+
return t;
|
|
10
|
+
};
|
|
11
|
+
return __assign.apply(this, arguments);
|
|
12
|
+
};
|
|
13
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
14
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
15
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
16
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
17
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
18
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
19
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
20
|
+
});
|
|
21
|
+
};
|
|
22
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
23
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
24
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
25
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
26
|
+
function step(op) {
|
|
27
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
28
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
29
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
30
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
31
|
+
switch (op[0]) {
|
|
32
|
+
case 0: case 1: t = op; break;
|
|
33
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
34
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
35
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
36
|
+
default:
|
|
37
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
38
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
39
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
40
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
41
|
+
if (t[2]) _.ops.pop();
|
|
42
|
+
_.trys.pop(); continue;
|
|
43
|
+
}
|
|
44
|
+
op = body.call(thisArg, _);
|
|
45
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
46
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
var __values = (this && this.__values) || function(o) {
|
|
50
|
+
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
51
|
+
if (m) return m.call(o);
|
|
52
|
+
if (o && typeof o.length === "number") return {
|
|
53
|
+
next: function () {
|
|
54
|
+
if (o && i >= o.length) o = void 0;
|
|
55
|
+
return { value: o && o[i++], done: !o };
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
59
|
+
};
|
|
60
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
61
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
62
|
+
if (!m) return o;
|
|
63
|
+
var i = m.call(o), r, ar = [], e;
|
|
64
|
+
try {
|
|
65
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
66
|
+
}
|
|
67
|
+
catch (error) { e = { error: error }; }
|
|
68
|
+
finally {
|
|
69
|
+
try {
|
|
70
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
71
|
+
}
|
|
72
|
+
finally { if (e) throw e.error; }
|
|
73
|
+
}
|
|
74
|
+
return ar;
|
|
75
|
+
};
|
|
76
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
77
|
+
exports.serializePathnameObjectKey = exports.serializeObjectConfigsToHeaders = exports.serializeObjectSsecOptionsToHeaders = exports.assignStringVariables = void 0;
|
|
78
|
+
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
79
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
80
|
+
var md5_js_1 = require("@aws-sdk/md5-js");
|
|
81
|
+
var aws_client_utils_1 = require("@aws-amplify/core/internals/aws-client-utils");
|
|
82
|
+
var utils_1 = require("../utils");
|
|
83
|
+
/**
|
|
84
|
+
* @internal
|
|
85
|
+
*/
|
|
86
|
+
var assignStringVariables = function (values) {
|
|
87
|
+
var e_1, _a;
|
|
88
|
+
var queryParams = {};
|
|
89
|
+
try {
|
|
90
|
+
for (var _b = __values(Object.entries(values)), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
91
|
+
var _d = __read(_c.value, 2), key = _d[0], value = _d[1];
|
|
92
|
+
if (value != null) {
|
|
93
|
+
queryParams[key] = value.toString();
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
98
|
+
finally {
|
|
99
|
+
try {
|
|
100
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
101
|
+
}
|
|
102
|
+
finally { if (e_1) throw e_1.error; }
|
|
103
|
+
}
|
|
104
|
+
return queryParams;
|
|
105
|
+
};
|
|
106
|
+
exports.assignStringVariables = assignStringVariables;
|
|
107
|
+
var serializeObjectSsecOptionsToHeaders = function (input) { return __awaiter(void 0, void 0, void 0, function () {
|
|
108
|
+
var getMd5Digest, _a, _b, _c, _d;
|
|
109
|
+
var _e;
|
|
110
|
+
return __generator(this, function (_f) {
|
|
111
|
+
switch (_f.label) {
|
|
112
|
+
case 0:
|
|
113
|
+
getMd5Digest = function (content) { return __awaiter(void 0, void 0, void 0, function () {
|
|
114
|
+
var md5Hasher;
|
|
115
|
+
return __generator(this, function (_a) {
|
|
116
|
+
md5Hasher = new md5_js_1.Md5();
|
|
117
|
+
md5Hasher.update((0, utils_1.utf8Encode)(content));
|
|
118
|
+
return [2 /*return*/, md5Hasher.digest()];
|
|
119
|
+
});
|
|
120
|
+
}); };
|
|
121
|
+
_a = exports.assignStringVariables;
|
|
122
|
+
_e = {
|
|
123
|
+
'x-amz-server-side-encryption-customer-algorithm': input.SSECustomerAlgorithm,
|
|
124
|
+
// base64 encoded is need
|
|
125
|
+
// see: https://docs.aws.amazon.com/AmazonS3/latest/userguide/ServerSideEncryptionCustomerKeys.html#specifying-s3-c-encryption
|
|
126
|
+
'x-amz-server-side-encryption-customer-key': input.SSECustomerKey && (0, utils_1.toBase64)(input.SSECustomerKey)
|
|
127
|
+
};
|
|
128
|
+
// Calculate the md5 digest of the the SSE-C key, for compatibility with AWS SDK
|
|
129
|
+
// see: https://github.com/aws/aws-sdk-js-v3/blob/91fc83307c38cc9cbe0b3acd919557d5b5b831d6/packages/middleware-ssec/src/index.ts#L36
|
|
130
|
+
_b = 'x-amz-server-side-encryption-customer-key-md5';
|
|
131
|
+
_c = input.SSECustomerKey;
|
|
132
|
+
if (!_c) return [3 /*break*/, 2];
|
|
133
|
+
_d = utils_1.toBase64;
|
|
134
|
+
return [4 /*yield*/, getMd5Digest(input.SSECustomerKey)];
|
|
135
|
+
case 1:
|
|
136
|
+
_c = _d.apply(void 0, [_f.sent()]);
|
|
137
|
+
_f.label = 2;
|
|
138
|
+
case 2: return [2 /*return*/, _a.apply(void 0, [(
|
|
139
|
+
// Calculate the md5 digest of the the SSE-C key, for compatibility with AWS SDK
|
|
140
|
+
// see: https://github.com/aws/aws-sdk-js-v3/blob/91fc83307c38cc9cbe0b3acd919557d5b5b831d6/packages/middleware-ssec/src/index.ts#L36
|
|
141
|
+
_e[_b] = _c,
|
|
142
|
+
_e)])];
|
|
143
|
+
}
|
|
144
|
+
});
|
|
145
|
+
}); };
|
|
146
|
+
exports.serializeObjectSsecOptionsToHeaders = serializeObjectSsecOptionsToHeaders;
|
|
147
|
+
/**
|
|
148
|
+
* Serailize the parameters for configuring the S3 object. Currently used by
|
|
149
|
+
* `putObject` and `createMultipartUpload` API.
|
|
150
|
+
*
|
|
151
|
+
* @internal
|
|
152
|
+
*/
|
|
153
|
+
var serializeObjectConfigsToHeaders = function (input) { return __awaiter(void 0, void 0, void 0, function () {
|
|
154
|
+
var _a;
|
|
155
|
+
var _b;
|
|
156
|
+
return __generator(this, function (_c) {
|
|
157
|
+
switch (_c.label) {
|
|
158
|
+
case 0:
|
|
159
|
+
_a = [{}];
|
|
160
|
+
return [4 /*yield*/, (0, exports.serializeObjectSsecOptionsToHeaders)(input)];
|
|
161
|
+
case 1: return [2 /*return*/, (__assign.apply(void 0, [__assign.apply(void 0, _a.concat([(_c.sent())])), (0, exports.assignStringVariables)(__assign({ 'x-amz-server-side-encryption': input.ServerSideEncryption, 'x-amz-server-side-encryption-aws-kms-key-id': input.SSEKMSKeyId, 'x-amz-acl': input.ACL, 'cache-control': input.CacheControl, 'content-disposition': input.ContentDisposition, 'content-language': input.ContentLanguage, 'content-encoding': input.ContentEncoding, 'content-type': input.ContentType, expires: (_b = input.Expires) === null || _b === void 0 ? void 0 : _b.toUTCString(), 'x-amz-tagging': input.Tagging }, serializeMetadata(input.Metadata)))]))];
|
|
162
|
+
}
|
|
163
|
+
});
|
|
164
|
+
}); };
|
|
165
|
+
exports.serializeObjectConfigsToHeaders = serializeObjectConfigsToHeaders;
|
|
166
|
+
var serializeMetadata = function (metadata) {
|
|
167
|
+
if (metadata === void 0) { metadata = {}; }
|
|
168
|
+
return Object.keys(metadata).reduce(function (acc, suffix) {
|
|
169
|
+
acc["x-amz-meta-".concat(suffix.toLowerCase())] = metadata[suffix];
|
|
170
|
+
return acc;
|
|
171
|
+
}, {});
|
|
172
|
+
};
|
|
173
|
+
/**
|
|
174
|
+
* Serialize the object key to a URL pathname.
|
|
175
|
+
* @see https://github.com/aws/aws-sdk-js-v3/blob/7ed7101dcc4e81038b6c7f581162b959e6b33a04/clients/client-s3/src/protocols/Aws_restXml.ts#L1108
|
|
176
|
+
*
|
|
177
|
+
* @internal
|
|
178
|
+
*/
|
|
179
|
+
var serializePathnameObjectKey = function (url, key) {
|
|
180
|
+
return (url.pathname.replace(/\/$/, '') +
|
|
181
|
+
"/".concat(key.split('/').map(aws_client_utils_1.extendedEncodeURIComponent).join('/')));
|
|
182
|
+
};
|
|
183
|
+
exports.serializePathnameObjectKey = serializePathnameObjectKey;
|
package/lib/Storage.d.ts
CHANGED
|
@@ -10,11 +10,11 @@ export declare class Storage {
|
|
|
10
10
|
private _pluggables;
|
|
11
11
|
/**
|
|
12
12
|
* Similar to the API module. This weak map allows users to cancel their in-flight request made using the Storage
|
|
13
|
-
* module. For every get or put request, a unique
|
|
14
|
-
*
|
|
15
|
-
* attempt to retrieve it's corresponding
|
|
13
|
+
* module. For every get or put request, a unique AbortConttroller will be generated and injected to it's underlying
|
|
14
|
+
* Xhr HTTP handler. This map maintains a mapping of Request to AbortController. When .cancel is invoked, it will
|
|
15
|
+
* attempt to retrieve it's corresponding abortController and cancel the in-flight request.
|
|
16
16
|
*/
|
|
17
|
-
private
|
|
17
|
+
private _abortControllerMap;
|
|
18
18
|
/**
|
|
19
19
|
* @public
|
|
20
20
|
*/
|
|
@@ -46,7 +46,7 @@ export declare class Storage {
|
|
|
46
46
|
* @return {Object} - Current configuration
|
|
47
47
|
*/
|
|
48
48
|
configure(config?: any): any;
|
|
49
|
-
private
|
|
49
|
+
private getAbortController;
|
|
50
50
|
private updateRequestToBeCancellable;
|
|
51
51
|
private isUploadTask;
|
|
52
52
|
/**
|
package/lib/Storage.js
CHANGED
|
@@ -1,11 +1,38 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
3
3
|
// SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
var __assign = (this && this.__assign) || function () {
|
|
5
|
+
__assign = Object.assign || function(t) {
|
|
6
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
7
|
+
s = arguments[i];
|
|
8
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
9
|
+
t[p] = s[p];
|
|
10
|
+
}
|
|
11
|
+
return t;
|
|
12
|
+
};
|
|
13
|
+
return __assign.apply(this, arguments);
|
|
14
|
+
};
|
|
15
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
16
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
17
|
+
if (!m) return o;
|
|
18
|
+
var i = m.call(o), r, ar = [], e;
|
|
19
|
+
try {
|
|
20
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
21
|
+
}
|
|
22
|
+
catch (error) { e = { error: error }; }
|
|
23
|
+
finally {
|
|
24
|
+
try {
|
|
25
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
26
|
+
}
|
|
27
|
+
finally { if (e) throw e.error; }
|
|
28
|
+
}
|
|
29
|
+
return ar;
|
|
30
|
+
};
|
|
4
31
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
-
|
|
32
|
+
exports.StorageInstance = exports.Storage = void 0;
|
|
6
33
|
var core_1 = require("@aws-amplify/core");
|
|
7
34
|
var providers_1 = require("./providers");
|
|
8
|
-
var
|
|
35
|
+
var utils_1 = require("./AwsClients/S3/utils");
|
|
9
36
|
var AWSS3UploadTask_1 = require("./providers/AWSS3UploadTask");
|
|
10
37
|
var logger = new core_1.ConsoleLogger('StorageClass');
|
|
11
38
|
var loggerStorageInstance = new core_1.ConsoleLogger('Storage'); // Logging relating to Storage instance management
|
|
@@ -21,7 +48,7 @@ var Storage = /** @class */ (function () {
|
|
|
21
48
|
function Storage() {
|
|
22
49
|
this._config = {};
|
|
23
50
|
this._pluggables = [];
|
|
24
|
-
this.
|
|
51
|
+
this._abortControllerMap = new WeakMap();
|
|
25
52
|
logger.debug('Storage Options', this._config);
|
|
26
53
|
this.get = this.get.bind(this);
|
|
27
54
|
this.put = this.put.bind(this);
|
|
@@ -75,7 +102,7 @@ var Storage = /** @class */ (function () {
|
|
|
75
102
|
logger.debug('configure Storage');
|
|
76
103
|
if (!config)
|
|
77
104
|
return this._config;
|
|
78
|
-
var amplifyConfig = core_1.parseAWSExports(config);
|
|
105
|
+
var amplifyConfig = (0, core_1.parseAWSExports)(config);
|
|
79
106
|
var storageConfig = (_a = amplifyConfig.Storage) !== null && _a !== void 0 ? _a : {};
|
|
80
107
|
var defaultProviderConfigKeys = [
|
|
81
108
|
'bucket',
|
|
@@ -86,6 +113,7 @@ var Storage = /** @class */ (function () {
|
|
|
86
113
|
'serverSideEncryption',
|
|
87
114
|
'SSECustomerAlgorithm',
|
|
88
115
|
'SSECustomerKey',
|
|
116
|
+
// TODO(AllanZhengYP): remove in V6.
|
|
89
117
|
'SSECustomerKeyMD5',
|
|
90
118
|
'SSEKMSKeyId',
|
|
91
119
|
];
|
|
@@ -97,7 +125,7 @@ var Storage = /** @class */ (function () {
|
|
|
97
125
|
storageConfig[DEFAULT_PROVIDER] = {};
|
|
98
126
|
}
|
|
99
127
|
Object.entries(storageConfig).forEach(function (_a) {
|
|
100
|
-
var _b =
|
|
128
|
+
var _b = __read(_a, 2), key = _b[0], value = _b[1];
|
|
101
129
|
if (key &&
|
|
102
130
|
defaultProviderConfigKeys.includes(key) &&
|
|
103
131
|
value !== undefined) {
|
|
@@ -108,7 +136,7 @@ var Storage = /** @class */ (function () {
|
|
|
108
136
|
// only update new values for each provider
|
|
109
137
|
Object.keys(storageConfig).forEach(function (providerName) {
|
|
110
138
|
if (typeof storageConfig[providerName] !== 'string') {
|
|
111
|
-
_this._config[providerName] =
|
|
139
|
+
_this._config[providerName] = __assign(__assign({}, _this._config[providerName]), storageConfig[providerName]);
|
|
112
140
|
}
|
|
113
141
|
});
|
|
114
142
|
this._pluggables.forEach(function (pluggable) {
|
|
@@ -119,11 +147,11 @@ var Storage = /** @class */ (function () {
|
|
|
119
147
|
}
|
|
120
148
|
return this._config;
|
|
121
149
|
};
|
|
122
|
-
Storage.prototype.
|
|
123
|
-
return
|
|
150
|
+
Storage.prototype.getAbortController = function () {
|
|
151
|
+
return new AbortController();
|
|
124
152
|
};
|
|
125
|
-
Storage.prototype.updateRequestToBeCancellable = function (request,
|
|
126
|
-
this.
|
|
153
|
+
Storage.prototype.updateRequestToBeCancellable = function (request, abortController) {
|
|
154
|
+
this._abortControllerMap.set(request, abortController);
|
|
127
155
|
};
|
|
128
156
|
Storage.prototype.isUploadTask = function (x) {
|
|
129
157
|
return (typeof x !== 'undefined' &&
|
|
@@ -134,9 +162,11 @@ var Storage = /** @class */ (function () {
|
|
|
134
162
|
if (request instanceof AWSS3UploadTask_1.AWSS3UploadTask) {
|
|
135
163
|
return request._cancel();
|
|
136
164
|
}
|
|
137
|
-
var
|
|
138
|
-
if (
|
|
139
|
-
|
|
165
|
+
var abortController = this._abortControllerMap.get(request);
|
|
166
|
+
if (abortController) {
|
|
167
|
+
// TODO: [v6] clean up the aborted promise in the weak map.
|
|
168
|
+
// Not doing it yet to avoid breaking changes when users may abort a request twice.
|
|
169
|
+
abortController.abort(message);
|
|
140
170
|
}
|
|
141
171
|
else {
|
|
142
172
|
logger.debug('The request does not map to any cancel token');
|
|
@@ -149,12 +179,12 @@ var Storage = /** @class */ (function () {
|
|
|
149
179
|
logger.debug('No plugin found with providerName', provider);
|
|
150
180
|
return Promise.reject('No plugin found in Storage for the provider');
|
|
151
181
|
}
|
|
152
|
-
var
|
|
182
|
+
var abortController = this.getAbortController();
|
|
153
183
|
if (typeof plugin.copy !== 'function') {
|
|
154
|
-
return Promise.reject(".copy is not implemented on provider "
|
|
184
|
+
return Promise.reject(".copy is not implemented on provider ".concat(plugin.getProviderName()));
|
|
155
185
|
}
|
|
156
|
-
var responsePromise = plugin.copy(src, dest,
|
|
157
|
-
this.updateRequestToBeCancellable(responsePromise,
|
|
186
|
+
var responsePromise = plugin.copy(src, dest, __assign(__assign({}, config), { abortSignal: abortController.signal }));
|
|
187
|
+
this.updateRequestToBeCancellable(responsePromise, abortController);
|
|
158
188
|
return responsePromise;
|
|
159
189
|
};
|
|
160
190
|
Storage.prototype.get = function (key, config) {
|
|
@@ -164,13 +194,13 @@ var Storage = /** @class */ (function () {
|
|
|
164
194
|
logger.debug('No plugin found with providerName', provider);
|
|
165
195
|
return Promise.reject('No plugin found in Storage for the provider');
|
|
166
196
|
}
|
|
167
|
-
var
|
|
168
|
-
var responsePromise = plugin.get(key,
|
|
169
|
-
this.updateRequestToBeCancellable(responsePromise,
|
|
197
|
+
var abortController = this.getAbortController();
|
|
198
|
+
var responsePromise = plugin.get(key, __assign(__assign({}, config), { abortSignal: abortController.signal }));
|
|
199
|
+
this.updateRequestToBeCancellable(responsePromise, abortController);
|
|
170
200
|
return responsePromise;
|
|
171
201
|
};
|
|
172
202
|
Storage.prototype.isCancelError = function (error) {
|
|
173
|
-
return
|
|
203
|
+
return (0, utils_1.isCancelError)(error);
|
|
174
204
|
};
|
|
175
205
|
Storage.prototype.getProperties = function (key, config) {
|
|
176
206
|
var provider = (config === null || config === void 0 ? void 0 : config.provider) || DEFAULT_PROVIDER;
|
|
@@ -179,12 +209,12 @@ var Storage = /** @class */ (function () {
|
|
|
179
209
|
logger.debug('No plugin found with providerName', provider);
|
|
180
210
|
throw new Error('No plugin found with providerName');
|
|
181
211
|
}
|
|
182
|
-
var
|
|
212
|
+
var abortController = this.getAbortController();
|
|
183
213
|
if (typeof plugin.getProperties !== 'function') {
|
|
184
|
-
return Promise.reject(".getProperties is not implemented on provider "
|
|
214
|
+
return Promise.reject(".getProperties is not implemented on provider ".concat(plugin.getProviderName()));
|
|
185
215
|
}
|
|
186
|
-
var responsePromise = plugin === null || plugin === void 0 ? void 0 : plugin.getProperties(key,
|
|
187
|
-
this.updateRequestToBeCancellable(responsePromise,
|
|
216
|
+
var responsePromise = plugin === null || plugin === void 0 ? void 0 : plugin.getProperties(key, __assign({}, config));
|
|
217
|
+
this.updateRequestToBeCancellable(responsePromise, abortController);
|
|
188
218
|
return responsePromise;
|
|
189
219
|
};
|
|
190
220
|
Storage.prototype.put = function (key, object, config) {
|
|
@@ -194,10 +224,10 @@ var Storage = /** @class */ (function () {
|
|
|
194
224
|
logger.debug('No plugin found with providerName', provider);
|
|
195
225
|
return Promise.reject('No plugin found in Storage for the provider');
|
|
196
226
|
}
|
|
197
|
-
var
|
|
198
|
-
var response = plugin.put(key, object,
|
|
227
|
+
var abortController = this.getAbortController();
|
|
228
|
+
var response = plugin.put(key, object, __assign(__assign({}, config), { abortSignal: abortController.signal }));
|
|
199
229
|
if (!this.isUploadTask(response)) {
|
|
200
|
-
this.updateRequestToBeCancellable(response,
|
|
230
|
+
this.updateRequestToBeCancellable(response, abortController);
|
|
201
231
|
}
|
|
202
232
|
return response;
|
|
203
233
|
};
|
|
@@ -236,11 +266,11 @@ var getInstance = function () {
|
|
|
236
266
|
var old_configure = _instance.configure;
|
|
237
267
|
_instance.configure = function (options) {
|
|
238
268
|
loggerStorageInstance.debug('storage configure called');
|
|
239
|
-
var vaultConfig =
|
|
269
|
+
var vaultConfig = __assign({}, old_configure.call(_instance, options));
|
|
240
270
|
// set level private for each provider for the vault
|
|
241
271
|
Object.keys(vaultConfig).forEach(function (providerName) {
|
|
242
272
|
if (typeof vaultConfig[providerName] !== 'string') {
|
|
243
|
-
vaultConfig[providerName] =
|
|
273
|
+
vaultConfig[providerName] = __assign(__assign({}, vaultConfig[providerName]), { level: 'private' });
|
|
244
274
|
}
|
|
245
275
|
});
|
|
246
276
|
loggerStorageInstance.debug('storage vault configure called');
|
|
@@ -250,4 +280,3 @@ var getInstance = function () {
|
|
|
250
280
|
};
|
|
251
281
|
exports.StorageInstance = getInstance();
|
|
252
282
|
core_1.Amplify.register(exports.StorageInstance);
|
|
253
|
-
//# sourceMappingURL=Storage.js.map
|
|
@@ -1,38 +1,47 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { ICredentials, StorageAction } from '@aws-amplify/core';
|
|
3
|
+
import type { Credentials as AwsCredentials } from '@aws-sdk/types';
|
|
4
|
+
import type { EventEmitter } from 'events';
|
|
3
5
|
import { StorageAccessLevel, CustomPrefix } from '../types';
|
|
4
|
-
import { InitializeMiddleware, InitializeHandlerOptions, FinalizeRequestHandlerOptions, FinalizeRequestMiddleware } from '@aws-sdk/types';
|
|
5
|
-
import { S3ClientConfig, S3Client } from '@aws-sdk/client-s3';
|
|
6
|
-
import { CancelTokenSource } from 'axios';
|
|
7
|
-
import * as events from 'events';
|
|
8
6
|
export declare const getPrefix: (config: {
|
|
9
7
|
credentials: ICredentials;
|
|
10
8
|
level?: StorageAccessLevel;
|
|
11
9
|
customPrefix?: CustomPrefix;
|
|
12
10
|
identityId?: string;
|
|
13
11
|
}) => string;
|
|
14
|
-
export declare const createPrefixMiddleware: (opt: Record<string, any>, key: string) => InitializeMiddleware<any, any>;
|
|
15
|
-
export declare const autoAdjustClockskewMiddleware: (config: S3ClientConfig) => FinalizeRequestMiddleware<any, any>;
|
|
16
|
-
export declare const autoAdjustClockskewMiddlewareOptions: FinalizeRequestHandlerOptions;
|
|
17
|
-
export declare const prefixMiddlewareOptions: InitializeHandlerOptions;
|
|
18
12
|
export declare const credentialsProvider: () => Promise<{
|
|
19
13
|
accessKeyId: any;
|
|
20
14
|
sessionToken: any;
|
|
21
15
|
secretAccessKey: any;
|
|
22
16
|
identityId: any;
|
|
23
17
|
authenticated: any;
|
|
24
|
-
} | {
|
|
25
|
-
accessKeyId: string;
|
|
26
|
-
secretAccessKey: string;
|
|
27
18
|
}>;
|
|
28
|
-
|
|
19
|
+
interface S3InputConfig {
|
|
20
|
+
credentials?: AwsCredentials;
|
|
29
21
|
region?: string;
|
|
30
|
-
cancelTokenSource?: CancelTokenSource;
|
|
31
|
-
dangerouslyConnectToHttpEndpointForTesting?: boolean;
|
|
32
22
|
useAccelerateEndpoint?: boolean;
|
|
33
|
-
|
|
23
|
+
abortSignal?: AbortSignal;
|
|
24
|
+
emitter?: EventEmitter;
|
|
25
|
+
storageAction: StorageAction;
|
|
26
|
+
dangerouslyConnectToHttpEndpointForTesting?: boolean;
|
|
27
|
+
}
|
|
28
|
+
export interface S3ResolvedConfig extends Omit<S3InputConfig, 'region' | 'credentials'> {
|
|
29
|
+
region: string;
|
|
30
|
+
userAgentValue?: string;
|
|
31
|
+
credentials: () => Promise<AwsCredentials>;
|
|
32
|
+
customEndpoint?: string;
|
|
33
|
+
forcePathStyle?: boolean;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* A function that persists the s3 configs, so we don't need to
|
|
37
|
+
* assign each config parameter for every s3 API call.
|
|
38
|
+
*
|
|
39
|
+
* @inernal
|
|
40
|
+
*/
|
|
41
|
+
export declare const loadS3Config: (config: S3InputConfig) => S3ResolvedConfig;
|
|
34
42
|
export declare const DEFAULT_PART_SIZE: number;
|
|
35
43
|
export declare const MAX_OBJECT_SIZE: number;
|
|
36
44
|
export declare const MAX_PARTS_COUNT = 10000;
|
|
37
45
|
export declare const DEFAULT_QUEUE_SIZE = 4;
|
|
38
46
|
export declare const calculatePartSize: (totalSize: number) => number;
|
|
47
|
+
export {};
|