Skip to content

Commit

Permalink
fix(aws-iot-actions-alpha): ForbiddenException: UnknownError when u…
Browse files Browse the repository at this point in the history
…sing `awsApiCall('IotData', 'publish', ...)`
  • Loading branch information
yamatatsu committed Aug 5, 2023
1 parent 972a06f commit c8258a6
Show file tree
Hide file tree
Showing 11 changed files with 32,861 additions and 50 deletions.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"version":"21.0.0"}
{"version":"33.0.0"}
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
{
"version": "21.0.0",
"version": "33.0.0",
"testCases": {
"integ.sns-topic-action": {
"sns-topic-action-test/DefaultTest": {
"stacks": [
"sns-topic-action-test-stack"
],
"diffAssets": false,
"stackUpdateWorkflow": true
"stackUpdateWorkflow": false,
"assertionStack": "sns-topic-action-test/DefaultTest/DeployAssert",
"assertionStackName": "snstopicactiontestDefaultTestDeployAssert7CEC369B"
}
},
"synthContext": {},
"enableLookups": false
}
}
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
{
"version": "21.0.0",
"version": "33.0.0",
"artifacts": {
"Tree": {
"type": "cdk:tree",
"properties": {
"file": "tree.json"
}
},
"sns-topic-action-test-stack.assets": {
"type": "cdk:asset-manifest",
"properties": {
Expand All @@ -23,7 +17,7 @@
"validateOnSynth": false,
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}",
"cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}",
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/c87dc7ff1f88e0f178feb918626ae53eb35d18f402d021b67c8aa0c5d83db94c.json",
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/70a6502801a44c7fa11d63bc39903614d0df0d60024ca19cd4c4cd741797ced7.json",
"requiresBootstrapStackVersion": 6,
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version",
"additionalDependencies": [
Expand Down Expand Up @@ -63,6 +57,30 @@
"data": "MyTopic86869434"
}
],
"/sns-topic-action-test-stack/MyQueue/Resource": [
{
"type": "aws:cdk:logicalId",
"data": "MyQueueE6CA6235"
}
],
"/sns-topic-action-test-stack/MyQueue/Policy/Resource": [
{
"type": "aws:cdk:logicalId",
"data": "MyQueuePolicy6BBEDDAC"
}
],
"/sns-topic-action-test-stack/MyQueue/snstopicactionteststackMyTopic94DD9DFA/Resource": [
{
"type": "aws:cdk:logicalId",
"data": "MyQueuesnstopicactionteststackMyTopic94DD9DFA7E2FA5E2"
}
],
"/sns-topic-action-test-stack/Exports/Output{\"Ref\":\"MyQueueE6CA6235\"}": [
{
"type": "aws:cdk:logicalId",
"data": "ExportsOutputRefMyQueueE6CA623512A57419"
}
],
"/sns-topic-action-test-stack/BootstrapVersion": [
{
"type": "aws:cdk:logicalId",
Expand All @@ -77,6 +95,96 @@
]
},
"displayName": "sns-topic-action-test-stack"
},
"snstopicactiontestDefaultTestDeployAssert7CEC369B.assets": {
"type": "cdk:asset-manifest",
"properties": {
"file": "snstopicactiontestDefaultTestDeployAssert7CEC369B.assets.json",
"requiresBootstrapStackVersion": 6,
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version"
}
},
"snstopicactiontestDefaultTestDeployAssert7CEC369B": {
"type": "aws:cloudformation:stack",
"environment": "aws://unknown-account/unknown-region",
"properties": {
"templateFile": "snstopicactiontestDefaultTestDeployAssert7CEC369B.template.json",
"validateOnSynth": false,
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-deploy-role-${AWS::AccountId}-${AWS::Region}",
"cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-cfn-exec-role-${AWS::AccountId}-${AWS::Region}",
"stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}/0a426876e4604ba67c355a680fe3b669bd8b2a029103f9a896fcd1433cf09d32.json",
"requiresBootstrapStackVersion": 6,
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version",
"additionalDependencies": [
"snstopicactiontestDefaultTestDeployAssert7CEC369B.assets"
],
"lookupRole": {
"arn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-lookup-role-${AWS::AccountId}-${AWS::Region}",
"requiresBootstrapStackVersion": 8,
"bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version"
}
},
"dependencies": [
"sns-topic-action-test-stack",
"snstopicactiontestDefaultTestDeployAssert7CEC369B.assets"
],
"metadata": {
"/sns-topic-action-test/DefaultTest/DeployAssert/AwsApiCallSQSpurgeQueue0080aee76c0c561f142ddb9a13ec7cc4/Default/Default": [
{
"type": "aws:cdk:logicalId",
"data": "AwsApiCallSQSpurgeQueue0080aee76c0c561f142ddb9a13ec7cc4"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/SingletonFunction1488541a7b23466481b69b4408076b81/Role": [
{
"type": "aws:cdk:logicalId",
"data": "SingletonFunction1488541a7b23466481b69b4408076b81Role37ABCE73"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/SingletonFunction1488541a7b23466481b69b4408076b81/Handler": [
{
"type": "aws:cdk:logicalId",
"data": "SingletonFunction1488541a7b23466481b69b4408076b81HandlerCD40AE9F"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/AwsApiCallIotDatapublish0e02a766e2fbbaa9d608b52a8e174d10/Default/Default": [
{
"type": "aws:cdk:logicalId",
"data": "AwsApiCallIotDatapublish0e02a766e2fbbaa9d608b52a8e174d10"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/AwsApiCallSQSreceiveMessage2339d0007bf8ec3f84ba0d037203c1f7/Default/Default": [
{
"type": "aws:cdk:logicalId",
"data": "AwsApiCallSQSreceiveMessage2339d0007bf8ec3f84ba0d037203c1f7"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/AwsApiCallSQSreceiveMessage2339d0007bf8ec3f84ba0d037203c1f7/AssertionResults": [
{
"type": "aws:cdk:logicalId",
"data": "AssertionResultsAwsApiCallSQSreceiveMessage2339d0007bf8ec3f84ba0d037203c1f7"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/BootstrapVersion": [
{
"type": "aws:cdk:logicalId",
"data": "BootstrapVersion"
}
],
"/sns-topic-action-test/DefaultTest/DeployAssert/CheckBootstrapVersion": [
{
"type": "aws:cdk:logicalId",
"data": "CheckBootstrapVersion"
}
]
},
"displayName": "sns-topic-action-test/DefaultTest/DeployAssert"
},
"Tree": {
"type": "cdk:tree",
"properties": {
"file": "tree.json"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
"version": "21.0.0",
"version": "33.0.0",
"files": {
"c87dc7ff1f88e0f178feb918626ae53eb35d18f402d021b67c8aa0c5d83db94c": {
"70a6502801a44c7fa11d63bc39903614d0df0d60024ca19cd4c4cd741797ced7": {
"source": {
"path": "sns-topic-action-test-stack.template.json",
"packaging": "file"
},
"destinations": {
"current_account-current_region": {
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
"objectKey": "c87dc7ff1f88e0f178feb918626ae53eb35d18f402d021b67c8aa0c5d83db94c.json",
"objectKey": "70a6502801a44c7fa11d63bc39903614d0df0d60024ca19cd4c4cd741797ced7.json",
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,74 @@
},
"MyTopic86869434": {
"Type": "AWS::SNS::Topic"
},
"MyQueueE6CA6235": {
"Type": "AWS::SQS::Queue",
"UpdateReplacePolicy": "Delete",
"DeletionPolicy": "Delete"
},
"MyQueuePolicy6BBEDDAC": {
"Type": "AWS::SQS::QueuePolicy",
"Properties": {
"PolicyDocument": {
"Statement": [
{
"Action": "sqs:SendMessage",
"Condition": {
"ArnEquals": {
"aws:SourceArn": {
"Ref": "MyTopic86869434"
}
}
},
"Effect": "Allow",
"Principal": {
"Service": "sns.amazonaws.com"
},
"Resource": {
"Fn::GetAtt": [
"MyQueueE6CA6235",
"Arn"
]
}
}
],
"Version": "2012-10-17"
},
"Queues": [
{
"Ref": "MyQueueE6CA6235"
}
]
}
},
"MyQueuesnstopicactionteststackMyTopic94DD9DFA7E2FA5E2": {
"Type": "AWS::SNS::Subscription",
"Properties": {
"Endpoint": {
"Fn::GetAtt": [
"MyQueueE6CA6235",
"Arn"
]
},
"Protocol": "sqs",
"TopicArn": {
"Ref": "MyTopic86869434"
}
},
"DependsOn": [
"MyQueuePolicy6BBEDDAC"
]
}
},
"Outputs": {
"ExportsOutputRefMyQueueE6CA623512A57419": {
"Value": {
"Ref": "MyQueueE6CA6235"
},
"Export": {
"Name": "sns-topic-action-test-stack:ExportsOutputRefMyQueueE6CA623512A57419"
}
}
},
"Parameters": {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"version": "33.0.0",
"files": {
"18f77fb224555ccad15f9c2e0f71ae6930fc011792c4f74ec74daaa2bbd9a33f": {
"source": {
"path": "asset.18f77fb224555ccad15f9c2e0f71ae6930fc011792c4f74ec74daaa2bbd9a33f.bundle",
"packaging": "zip"
},
"destinations": {
"current_account-current_region": {
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
"objectKey": "18f77fb224555ccad15f9c2e0f71ae6930fc011792c4f74ec74daaa2bbd9a33f.zip",
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
}
}
},
"0a426876e4604ba67c355a680fe3b669bd8b2a029103f9a896fcd1433cf09d32": {
"source": {
"path": "snstopicactiontestDefaultTestDeployAssert7CEC369B.template.json",
"packaging": "file"
},
"destinations": {
"current_account-current_region": {
"bucketName": "cdk-hnb659fds-assets-${AWS::AccountId}-${AWS::Region}",
"objectKey": "0a426876e4604ba67c355a680fe3b669bd8b2a029103f9a896fcd1433cf09d32.json",
"assumeRoleArn": "arn:${AWS::Partition}:iam::${AWS::AccountId}:role/cdk-hnb659fds-file-publishing-role-${AWS::AccountId}-${AWS::Region}"
}
}
}
},
"dockerImages": {}
}
Loading

0 comments on commit c8258a6

Please sign in to comment.