Skip to content

Commit 641f9e8

Browse files
authored
fix(events-targets): AwsApi fails when SDKv3 Command expects Uint8Array (#27034)
In #27002 we have migrated the AwsApi Construct to SDKv3. However some SDKv3 Commands expect a `Uint8Array` in places where SDKv2 previously would accept a `string`. This is a problem because handler input is passed directly into the SDK calls and the input can only contain JSON data types. To solves this, we keep a list of SDK actions and parameters that should be coerced to `Uint8Array`. ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent c0a46e6 commit 641f9e8

File tree

168 files changed

+55382
-42397
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+55382
-42397
lines changed
Large diffs are not rendered by default.
Large diffs are not rendered by default.

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2-actions/test/integ.cognito.js.snapshot/integ-cognito.assets.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
{
22
"version": "34.0.0",
33
"files": {
4-
"d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf": {
4+
"a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e": {
55
"source": {
6-
"path": "asset.d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf",
6+
"path": "asset.a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e",
77
"packaging": "zip"
88
},
99
"destinations": {
1010
"current_account-current_region": {
1111
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
12-
"objectKey": "d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf.zip",
12+
"objectKey": "a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e.zip",
1313
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
1414
}
1515
}
@@ -27,15 +27,15 @@
2727
}
2828
}
2929
},
30-
"f9d7a609d78100aca72b5fe61c968d55e9fc580b4a61d89e622350fabdcb4da6": {
30+
"c165610285472b5d9e28503595dac076e4edcf88340a3703fd508bcc6f8ba844": {
3131
"source": {
3232
"path": "integ-cognito.template.json",
3333
"packaging": "file"
3434
},
3535
"destinations": {
3636
"current_account-current_region": {
3737
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
38-
"objectKey": "f9d7a609d78100aca72b5fe61c968d55e9fc580b4a61d89e622350fabdcb4da6.json",
38+
"objectKey": "c165610285472b5d9e28503595dac076e4edcf88340a3703fd508bcc6f8ba844.json",
3939
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
4040
}
4141
}

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2-actions/test/integ.cognito.js.snapshot/integ-cognito.template.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -827,7 +827,7 @@
827827
"S3Bucket": {
828828
"Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
829829
},
830-
"S3Key": "d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf.zip"
830+
"S3Key": "a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e.zip"
831831
},
832832
"Handler": "index.handler",
833833
"Role": {

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2-actions/test/integ.cognito.js.snapshot/integtestcognitoDefaultTestDeployAssert6F2623C9.assets.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
11
{
22
"version": "34.0.0",
33
"files": {
4-
"92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2": {
4+
"607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a": {
55
"source": {
6-
"path": "asset.92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2.bundle",
6+
"path": "asset.607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a.bundle",
77
"packaging": "zip"
88
},
99
"destinations": {
1010
"current_account-current_region": {
1111
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
12-
"objectKey": "92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2.zip",
12+
"objectKey": "607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a.zip",
1313
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
1414
}
1515
}
1616
},
17-
"c42eb6e89441b92158b8079ee0a6323db61c7c6e1c4cee046b8899317ed64983": {
17+
"b5d1cbbb6997f2984e3f157bb49259729d12b1fbe0510a9562b1a7f93dd75185": {
1818
"source": {
1919
"path": "integtestcognitoDefaultTestDeployAssert6F2623C9.template.json",
2020
"packaging": "file"
2121
},
2222
"destinations": {
2323
"current_account-current_region": {
2424
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
25-
"objectKey": "c42eb6e89441b92158b8079ee0a6323db61c7c6e1c4cee046b8899317ed64983.json",
25+
"objectKey": "b5d1cbbb6997f2984e3f157bb49259729d12b1fbe0510a9562b1a7f93dd75185.json",
2626
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
2727
}
2828
}

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2-actions/test/integ.cognito.js.snapshot/integtestcognitoDefaultTestDeployAssert6F2623C9.template.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
}
2828
},
2929
"flattenResponse": "false",
30-
"salt": "1694000253228"
30+
"salt": "1694103850471"
3131
},
3232
"UpdateReplacePolicy": "Delete",
3333
"DeletionPolicy": "Delete"
@@ -127,7 +127,7 @@
127127
"S3Bucket": {
128128
"Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
129129
},
130-
"S3Key": "92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2.zip"
130+
"S3Key": "607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a.zip"
131131
},
132132
"Timeout": 120,
133133
"Handler": "index.handler",

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2-actions/test/integ.cognito.js.snapshot/manifest.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"validateOnSynth": false,
1818
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}",
1919
"cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}",
20-
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/f9d7a609d78100aca72b5fe61c968d55e9fc580b4a61d89e622350fabdcb4da6.json",
20+
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c165610285472b5d9e28503595dac076e4edcf88340a3703fd508bcc6f8ba844.json",
2121
"requiresBootstrapStackVersion": 6,
2222
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version",
2323
"additionalDependencies": [
@@ -316,7 +316,7 @@
316316
"validateOnSynth": false,
317317
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}",
318318
"cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}",
319-
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c42eb6e89441b92158b8079ee0a6323db61c7c6e1c4cee046b8899317ed64983.json",
319+
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/b5d1cbbb6997f2984e3f157bb49259729d12b1fbe0510a9562b1a7f93dd75185.json",
320320
"requiresBootstrapStackVersion": 6,
321321
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version",
322322
"additionalDependencies": [

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2-actions/test/integ.cognito.js.snapshot/tree.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1362,7 +1362,7 @@
13621362
"s3Bucket": {
13631363
"Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
13641364
},
1365-
"s3Key": "d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf.zip"
1365+
"s3Key": "a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e.zip"
13661366
},
13671367
"handler": "index.handler",
13681368
"role": {

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2/test/integ.alb.oidc.js.snapshot/IntegAlbOidc.assets.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,15 @@
1414
}
1515
}
1616
},
17-
"d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf": {
17+
"a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e": {
1818
"source": {
19-
"path": "asset.d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf",
19+
"path": "asset.a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e",
2020
"packaging": "zip"
2121
},
2222
"destinations": {
2323
"current_account-current_region": {
2424
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
25-
"objectKey": "d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf.zip",
25+
"objectKey": "a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e.zip",
2626
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
2727
}
2828
}
@@ -40,15 +40,15 @@
4040
}
4141
}
4242
},
43-
"ad72caaa8b80f2a6a7f4ac8cd7d7d967be4712cf0ee0fd11951c6df0a91c54b3": {
43+
"6c32973df676e20c6e121503a90e56ad935431a5c053e4c60523c0792a585f16": {
4444
"source": {
4545
"path": "IntegAlbOidc.template.json",
4646
"packaging": "file"
4747
},
4848
"destinations": {
4949
"current_account-current_region": {
5050
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
51-
"objectKey": "ad72caaa8b80f2a6a7f4ac8cd7d7d967be4712cf0ee0fd11951c6df0a91c54b3.json",
51+
"objectKey": "6c32973df676e20c6e121503a90e56ad935431a5c053e4c60523c0792a585f16.json",
5252
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
5353
}
5454
}

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2/test/integ.alb.oidc.js.snapshot/IntegAlbOidc.template.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -895,7 +895,7 @@
895895
"S3Bucket": {
896896
"Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
897897
},
898-
"S3Key": "d64690b87ee4eb4d8bbabafe26f88d8cc557bb629a158ed5fb182b8e48da1bbf.zip"
898+
"S3Key": "a7daad7bacb0e514491653ee581b9a6554d563c3c58935e94abf501b66781c2e.zip"
899899
},
900900
"Handler": "index.handler",
901901
"Role": {

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2/test/integ.alb.oidc.js.snapshot/IntegTestAlbOidcDefaultTestDeployAssert2476ECB6.assets.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
11
{
22
"version": "34.0.0",
33
"files": {
4-
"92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2": {
4+
"607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a": {
55
"source": {
6-
"path": "asset.92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2.bundle",
6+
"path": "asset.607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a.bundle",
77
"packaging": "zip"
88
},
99
"destinations": {
1010
"current_account-current_region": {
1111
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
12-
"objectKey": "92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2.zip",
12+
"objectKey": "607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a.zip",
1313
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
1414
}
1515
}
1616
},
17-
"2816e2779dbb67802899b9e298d03480c1a2cc3bbf42e9012eccbe0871fb7e42": {
17+
"fe21050aaa563a6b08d572d79a0f2937612f774a54171105fd072b0df021a107": {
1818
"source": {
1919
"path": "IntegTestAlbOidcDefaultTestDeployAssert2476ECB6.template.json",
2020
"packaging": "file"
2121
},
2222
"destinations": {
2323
"current_account-current_region": {
2424
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
25-
"objectKey": "2816e2779dbb67802899b9e298d03480c1a2cc3bbf42e9012eccbe0871fb7e42.json",
25+
"objectKey": "fe21050aaa563a6b08d572d79a0f2937612f774a54171105fd072b0df021a107.json",
2626
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
2727
}
2828
}

packages/@aws-cdk-testing/framework-integ/test/aws-elasticloadbalancingv2/test/integ.alb.oidc.js.snapshot/IntegTestAlbOidcDefaultTestDeployAssert2476ECB6.template.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
}
2828
},
2929
"flattenResponse": "false",
30-
"salt": "1694000254631"
30+
"salt": "1694103851652"
3131
},
3232
"UpdateReplacePolicy": "Delete",
3333
"DeletionPolicy": "Delete"
@@ -127,7 +127,7 @@
127127
"S3Bucket": {
128128
"Fn::Sub": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}"
129129
},
130-
"S3Key": "92519e926ac4ba644c6184363d536269cb0557fe7acc3593ae702e5a8b8e81a2.zip"
130+
"S3Key": "607f3e7ab05e31100a3d8b37a7c8b7c265265ddd82d3625781b6c940b54b6e6a.zip"
131131
},
132132
"Timeout": 120,
133133
"Handler": "index.handler",

0 commit comments

Comments
 (0)