Skip to content

Commit 4599aa3

Browse files
authored
feat(cloudwatch): add TableWidget (#29078)
### Issue # (if applicable) closes #28975. ### Reason for this change add support for table widget https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/add_remove_table_dashboard.html ### Description of changes add a new `TableWidget` and its supporting property classes/interfaces ### Description of how you validated changes added both unit/integ tests ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md) ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
1 parent c3c771c commit 4599aa3

File tree

13 files changed

+1035
-1
lines changed

13 files changed

+1035
-1
lines changed

packages/@aws-cdk-testing/framework-integ/test/aws-cloudwatch/test/integ.table-widget.js.snapshot/TableWidget.assets.json

Lines changed: 19 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
{
2+
"Resources": {
3+
"Dashboard9E4231ED": {
4+
"Type": "AWS::CloudWatch::Dashboard",
5+
"Properties": {
6+
"DashboardBody": {
7+
"Fn::Join": [
8+
"",
9+
[
10+
"{\"widgets\":[{\"type\":\"metric\",\"width\":12,\"height\":12,\"x\":0,\"y\":0,\"properties\":{\"title\":\"Table\",\"view\":\"table\",\"table\":{\"layout\":\"horizontal\",\"showTimeSeriesData\":true,\"stickySummary\":false,\"summaryColumns\":[]},\"region\":\"",
11+
{
12+
"Ref": "AWS::Region"
13+
},
14+
"\",\"metrics\":[[\"CDK/Test\",\"Metric\",{\"stat\":\"Minimum\"}]],\"annotations\":{\"horizontal\":[{\"value\":1000,\"color\":\"#d62728\",\"fill\":\"above\"},[{\"value\":500,\"color\":\"#ff7f0e\"},{\"value\":1000}],{\"value\":500,\"color\":\"#2ca02c\",\"fill\":\"below\"}]},\"yAxis\":{\"left\":{\"showUnits\":true}},\"singleValueFullPrecision\":true,\"period\":60}}]}"
15+
]
16+
]
17+
}
18+
}
19+
}
20+
},
21+
"Parameters": {
22+
"BootstrapVersion": {
23+
"Type": "AWS::SSM::Parameter::Value<String>",
24+
"Default": "/cdk-bootstrap/hnb659fds/version",
25+
"Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]"
26+
}
27+
},
28+
"Rules": {
29+
"CheckBootstrapVersion": {
30+
"Assertions": [
31+
{
32+
"Assert": {
33+
"Fn::Not": [
34+
{
35+
"Fn::Contains": [
36+
[
37+
"1",
38+
"2",
39+
"3",
40+
"4",
41+
"5"
42+
],
43+
{
44+
"Ref": "BootstrapVersion"
45+
}
46+
]
47+
}
48+
]
49+
},
50+
"AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI."
51+
}
52+
]
53+
}
54+
}
55+
}

packages/@aws-cdk-testing/framework-integ/test/aws-cloudwatch/test/integ.table-widget.js.snapshot/TableWidgetTestDefaultTestDeployAssertA94EAD9F.assets.json

Lines changed: 19 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-cloudwatch/test/integ.table-widget.js.snapshot/TableWidgetTestDefaultTestDeployAssertA94EAD9F.template.json

Lines changed: 36 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-cloudwatch/test/integ.table-widget.js.snapshot/cdk.out

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-cloudwatch/test/integ.table-widget.js.snapshot/integ.json

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/@aws-cdk-testing/framework-integ/test/aws-cloudwatch/test/integ.table-widget.js.snapshot/manifest.json

Lines changed: 113 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)