cdk-lambda-subminute 2.0.360 → 2.0.362
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/.jsii +16 -3
- package/lib/cdk-lambda-subminute.js +3 -3
- package/node_modules/aws-sdk/README.md +1 -1
- package/node_modules/aws-sdk/apis/acm-pca-2017-08-22.min.json +26 -15
- package/node_modules/aws-sdk/apis/acm-pca-2017-08-22.waiters2.json +1 -1
- package/node_modules/aws-sdk/apis/ec2-2016-11-15.min.json +12 -0
- package/node_modules/aws-sdk/apis/lightsail-2016-11-28.min.json +11 -2
- package/node_modules/aws-sdk/apis/outposts-2019-12-03.min.json +0 -1
- package/node_modules/aws-sdk/apis/rds-2014-10-31.min.json +334 -196
- package/node_modules/aws-sdk/apis/s3-2006-03-01.min.json +59 -49
- package/node_modules/aws-sdk/apis/storagegateway-2013-06-30.min.json +3 -1
- package/node_modules/aws-sdk/clients/acmpca.d.ts +13 -3
- package/node_modules/aws-sdk/clients/ec2.d.ts +20 -4
- package/node_modules/aws-sdk/clients/ecs.d.ts +9 -6
- package/node_modules/aws-sdk/clients/lightsail.d.ts +8 -0
- package/node_modules/aws-sdk/clients/outposts.d.ts +1 -1
- package/node_modules/aws-sdk/clients/rds.d.ts +175 -5
- package/node_modules/aws-sdk/clients/s3.d.ts +11 -2
- package/node_modules/aws-sdk/clients/storagegateway.d.ts +16 -8
- package/node_modules/aws-sdk/dist/aws-sdk-core-react-native.js +1 -1
- package/node_modules/aws-sdk/dist/aws-sdk-react-native.js +34 -9
- package/node_modules/aws-sdk/dist/aws-sdk.js +436 -249
- package/node_modules/aws-sdk/dist/aws-sdk.min.js +76 -76
- package/node_modules/aws-sdk/lib/core.js +1 -1
- package/node_modules/aws-sdk/lib/services/s3.js +25 -0
- package/node_modules/aws-sdk/package.json +1 -1
- package/node_modules/aws-sdk/scripts/lib/set-s3-expires-string.js +53 -0
- package/node_modules/aws-sdk/scripts/region-checker/allowlist.js +9 -9
- package/node_modules/aws-sdk/scripts/translate-api +2 -1
- package/package.json +2 -2
@@ -119,6 +119,7 @@ AWS.util.update(AWS.S3.prototype, {
|
|
119
119
|
* @api private
|
120
120
|
*/
|
121
121
|
setupRequestListeners: function setupRequestListeners(request) {
|
122
|
+
request.addListener('validateResponse', this.setExpiresString);
|
122
123
|
var prependListener = true;
|
123
124
|
request.addListener('validate', this.validateScheme);
|
124
125
|
request.addListener('validate', this.validateBucketName, prependListener);
|
@@ -1284,6 +1285,30 @@ AWS.util.update(AWS.S3.prototype, {
|
|
1284
1285
|
var uploader = new AWS.S3.ManagedUpload(options);
|
1285
1286
|
if (typeof callback === 'function') uploader.send(callback);
|
1286
1287
|
return uploader;
|
1288
|
+
},
|
1289
|
+
|
1290
|
+
/**
|
1291
|
+
* @api private
|
1292
|
+
*/
|
1293
|
+
setExpiresString: function setExpiresString(response) {
|
1294
|
+
// Check if response contains Expires value, and populate ExpiresString.
|
1295
|
+
if (response && response.httpResponse && response.httpResponse.headers) {
|
1296
|
+
if ('expires' in response.httpResponse.headers) {
|
1297
|
+
response.httpResponse.headers.expiresstring = response.httpResponse.headers.expires;
|
1298
|
+
}
|
1299
|
+
}
|
1300
|
+
|
1301
|
+
// Check if value in Expires is not a Date using parseTimestamp.
|
1302
|
+
try {
|
1303
|
+
if (response && response.httpResponse && response.httpResponse.headers) {
|
1304
|
+
if ('expires' in response.httpResponse.headers) {
|
1305
|
+
AWS.util.date.parseTimestamp(response.httpResponse.headers.expires);
|
1306
|
+
}
|
1307
|
+
}
|
1308
|
+
} catch (e) {
|
1309
|
+
console.log('AWS SDK', '(warning)', e);
|
1310
|
+
delete response.httpResponse.headers.expires;
|
1311
|
+
}
|
1287
1312
|
}
|
1288
1313
|
});
|
1289
1314
|
|
@@ -0,0 +1,53 @@
|
|
1
|
+
/**
|
2
|
+
* Sets model overrides for S3 ExpiresString.
|
3
|
+
*/
|
4
|
+
module.exports = function setS3ExpiresString(model) {
|
5
|
+
if (model.metadata.serviceId === 'S3') {
|
6
|
+
var newShapes = {};
|
7
|
+
for (var shapeId in model.shapes) {
|
8
|
+
newShapes[shapeId] = model.shapes[shapeId];
|
9
|
+
if (shapeId === 'Expires') {
|
10
|
+
// preserve timestamp type for Expires.
|
11
|
+
newShapes[shapeId] = {};
|
12
|
+
newShapes[shapeId].type = 'timestamp';
|
13
|
+
|
14
|
+
// add ExpiresString
|
15
|
+
newShapes['ExpiresString'] = {
|
16
|
+
type: 'string'
|
17
|
+
};
|
18
|
+
}
|
19
|
+
}
|
20
|
+
model.shapes = newShapes;
|
21
|
+
|
22
|
+
for (var operationKey in model.operations) {
|
23
|
+
var op = model.operations[operationKey];
|
24
|
+
if (!op.output || !op.output.shape) {
|
25
|
+
continue;
|
26
|
+
}
|
27
|
+
var output = model.shapes[op.output.shape];
|
28
|
+
if (!output || !output.members) {
|
29
|
+
continue;
|
30
|
+
}
|
31
|
+
if ('Expires' in output.members) {
|
32
|
+
var newMembers = {};
|
33
|
+
for (var memberKey in output.members) {
|
34
|
+
newMembers[memberKey] = output.members[memberKey];
|
35
|
+
if (memberKey === 'Expires') {
|
36
|
+
newMembers['ExpiresString'] = Object.assign({}, newMembers[memberKey], {
|
37
|
+
'shape': 'ExpiresString',
|
38
|
+
'location': 'header',
|
39
|
+
'locationName': 'ExpiresString'
|
40
|
+
});
|
41
|
+
|
42
|
+
newMembers[memberKey].deprecated = true;
|
43
|
+
newMembers[memberKey].documentation = 'Deprecated in favor of ExpiresString.';
|
44
|
+
}
|
45
|
+
}
|
46
|
+
output.members = newMembers;
|
47
|
+
}
|
48
|
+
}
|
49
|
+
|
50
|
+
return true;
|
51
|
+
}
|
52
|
+
return false;
|
53
|
+
};
|
@@ -40,17 +40,17 @@ var allowlist = {
|
|
40
40
|
'/services/s3.js': [
|
41
41
|
87,
|
42
42
|
88,
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
773,
|
43
|
+
261,
|
44
|
+
263,
|
45
|
+
276,
|
46
|
+
282,
|
47
|
+
642,
|
48
|
+
644,
|
49
|
+
763,
|
51
50
|
774,
|
52
51
|
775,
|
53
|
-
|
52
|
+
776,
|
53
|
+
781
|
54
54
|
],
|
55
55
|
'/token/sso_token_provider.js': [
|
56
56
|
60
|
@@ -3,6 +3,7 @@
|
|
3
3
|
var fs = require('fs');
|
4
4
|
var Translator = require('./lib/translator');
|
5
5
|
var removeEventStreamOperations = require('./lib/remove-event-stream-ops').removeEventStreamOperations;
|
6
|
+
var setS3ExpiresString = require('./lib/set-s3-expires-string');
|
6
7
|
var util = require('util');
|
7
8
|
var path = require('path');
|
8
9
|
|
@@ -24,7 +25,7 @@ function ApiTranslator(basePath) {
|
|
24
25
|
ApiTranslator.prototype.minimizeFile = function minimizeFile(filepath) {
|
25
26
|
var opath = filepath.replace(/\.normal\.json$/, '.min.json');
|
26
27
|
var data = JSON.parse(fs.readFileSync(path.join(this._apisPath, filepath)).toString());
|
27
|
-
var didModify = removeEventStreamOperations(data);
|
28
|
+
var didModify = removeEventStreamOperations(data) || setS3ExpiresString(data);
|
28
29
|
if (didModify) {
|
29
30
|
// original model modified, replace existing normal.json so docs/ts definitions are accurate
|
30
31
|
fs.writeFileSync(path.join(this._apisPath, filepath), JSON.stringify(data, null, ' '));
|
package/package.json
CHANGED
@@ -67,7 +67,7 @@
|
|
67
67
|
},
|
68
68
|
"dependencies": {
|
69
69
|
"aws-cdk-lib": "^2.95.0",
|
70
|
-
"aws-sdk": "^2.
|
70
|
+
"aws-sdk": "^2.1544.0",
|
71
71
|
"constructs": "^10.0.5"
|
72
72
|
},
|
73
73
|
"bundledDependencies": [
|
@@ -89,7 +89,7 @@
|
|
89
89
|
],
|
90
90
|
"main": "lib/index.js",
|
91
91
|
"license": "Apache-2.0",
|
92
|
-
"version": "2.0.
|
92
|
+
"version": "2.0.362",
|
93
93
|
"jest": {
|
94
94
|
"testMatch": [
|
95
95
|
"<rootDir>/src/**/__tests__/**/*.ts?(x)",
|