aws-sdk-cloudwatch 1.25.0 → 1.26.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a1ee506063533874a56e478ffd19bbddf8f87376
4
- data.tar.gz: f2fae9e67b8cf4337e1d88ac8d5c40e8ae840f66
3
+ metadata.gz: f10b31ef02006bb4f4ec30b42ae3953aaf17f834
4
+ data.tar.gz: 329c243b9220db03c7af99168917bcc1d4ade397
5
5
  SHA512:
6
- metadata.gz: 2c5d65bcb86dbed724da782c2ee5488c52eeefc11021472d8e8e41c09b4db3170db62cd73605d53e07cd938b017621ea41bdce59681a402ad018e49ce4bcb9e3
7
- data.tar.gz: 6c6ec833d9544fc281951317548cf1f5997a005906b90828c83a955992f9b23d150e20b57811b0d88036fede200389158ea5038731e99f15191c6532846948fa
6
+ metadata.gz: ce533992a51ddb63d2320cb8b7e19cb5e737baafff504c8f1acf66b9dcfe5c0c93562fe9900009283db74609c499b1c623fb560acc86246cb2e61fbf0df6964c
7
+ data.tar.gz: cab12dcd9fdae0cf8b377c63df50635e2bd6d1adb73d58bc2485a8361893d28a42126e8627d02c4ebae74166c0214e782bfa78dd8a1811d124f39d08e7ac1f26
@@ -45,6 +45,6 @@ require_relative 'aws-sdk-cloudwatch/customizations'
45
45
  # @service
46
46
  module Aws::CloudWatch
47
47
 
48
- GEM_VERSION = '1.25.0'
48
+ GEM_VERSION = '1.26.0'
49
49
 
50
50
  end
@@ -104,7 +104,8 @@ module Aws::CloudWatch
104
104
  data[:state_updated_timestamp]
105
105
  end
106
106
 
107
- # The name of the metric associated with the alarm.
107
+ # The name of the metric associated with the alarm, if this is an alarm
108
+ # based on a single metric.
108
109
  # @return [String]
109
110
  def metric_name
110
111
  data[:metric_name]
@@ -192,12 +193,23 @@ module Aws::CloudWatch
192
193
  data[:evaluate_low_sample_count_percentile]
193
194
  end
194
195
 
195
-
196
+ # An array of MetricDataQuery structures, used in an alarm based on a
197
+ # metric math expression. Each structure either retrieves a metric or
198
+ # performs a math expression. One item in the Metrics array is the math
199
+ # expression that the alarm watches. This expression by designated by
200
+ # having `ReturnValue` set to true.
196
201
  # @return [Array<Types::MetricDataQuery>]
197
202
  def metrics
198
203
  data[:metrics]
199
204
  end
200
205
 
206
+ # In an alarm based on an anomaly detection model, this is the ID of the
207
+ # `ANOMALY_DETECTION_BAND` function used as the threshold for the alarm.
208
+ # @return [String]
209
+ def threshold_metric_id
210
+ data[:threshold_metric_id]
211
+ end
212
+
201
213
  # @!endgroup
202
214
 
203
215
  # @return [Client]
@@ -277,6 +277,46 @@ module Aws::CloudWatch
277
277
  req.send_request(options)
278
278
  end
279
279
 
280
+ # Deletes the specified anomaly detection model from your account.
281
+ #
282
+ # @option params [required, String] :namespace
283
+ # The namespace associated with the anomaly detection model to delete.
284
+ #
285
+ # @option params [required, String] :metric_name
286
+ # The metric name associated with the anomaly detection model to delete.
287
+ #
288
+ # @option params [Array<Types::Dimension>] :dimensions
289
+ # The metric dimensions associated with the anomaly detection model to
290
+ # delete.
291
+ #
292
+ # @option params [required, String] :stat
293
+ # The statistic associated with the anomaly detection model to delete.
294
+ #
295
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
296
+ #
297
+ # @example Request syntax with placeholder values
298
+ #
299
+ # resp = client.delete_anomaly_detector({
300
+ # namespace: "Namespace", # required
301
+ # metric_name: "MetricName", # required
302
+ # dimensions: [
303
+ # {
304
+ # name: "DimensionName", # required
305
+ # value: "DimensionValue", # required
306
+ # },
307
+ # ],
308
+ # stat: "Stat", # required
309
+ # })
310
+ #
311
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DeleteAnomalyDetector AWS API Documentation
312
+ #
313
+ # @overload delete_anomaly_detector(params = {})
314
+ # @param [Hash] params ({})
315
+ def delete_anomaly_detector(params = {}, options = {})
316
+ req = build_request(:delete_anomaly_detector, params)
317
+ req.send_request(options)
318
+ end
319
+
280
320
  # Deletes all dashboards that you specify. You may specify up to 100
281
321
  # dashboards to delete. If there is an error during this call, no
282
322
  # dashboards are deleted.
@@ -432,7 +472,7 @@ module Aws::CloudWatch
432
472
  # resp.metric_alarms[0].evaluation_periods #=> Integer
433
473
  # resp.metric_alarms[0].datapoints_to_alarm #=> Integer
434
474
  # resp.metric_alarms[0].threshold #=> Float
435
- # resp.metric_alarms[0].comparison_operator #=> String, one of "GreaterThanOrEqualToThreshold", "GreaterThanThreshold", "LessThanThreshold", "LessThanOrEqualToThreshold"
475
+ # resp.metric_alarms[0].comparison_operator #=> String, one of "GreaterThanOrEqualToThreshold", "GreaterThanThreshold", "LessThanThreshold", "LessThanOrEqualToThreshold", "LessThanLowerOrGreaterThanUpperThreshold", "LessThanLowerThreshold", "GreaterThanUpperThreshold"
436
476
  # resp.metric_alarms[0].treat_missing_data #=> String
437
477
  # resp.metric_alarms[0].evaluate_low_sample_count_percentile #=> String
438
478
  # resp.metric_alarms[0].metrics #=> Array
@@ -448,6 +488,7 @@ module Aws::CloudWatch
448
488
  # resp.metric_alarms[0].metrics[0].expression #=> String
449
489
  # resp.metric_alarms[0].metrics[0].label #=> String
450
490
  # resp.metric_alarms[0].metrics[0].return_data #=> Boolean
491
+ # resp.metric_alarms[0].threshold_metric_id #=> String
451
492
  # resp.next_token #=> String
452
493
  #
453
494
  # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DescribeAlarms AWS API Documentation
@@ -538,7 +579,7 @@ module Aws::CloudWatch
538
579
  # resp.metric_alarms[0].evaluation_periods #=> Integer
539
580
  # resp.metric_alarms[0].datapoints_to_alarm #=> Integer
540
581
  # resp.metric_alarms[0].threshold #=> Float
541
- # resp.metric_alarms[0].comparison_operator #=> String, one of "GreaterThanOrEqualToThreshold", "GreaterThanThreshold", "LessThanThreshold", "LessThanOrEqualToThreshold"
582
+ # resp.metric_alarms[0].comparison_operator #=> String, one of "GreaterThanOrEqualToThreshold", "GreaterThanThreshold", "LessThanThreshold", "LessThanOrEqualToThreshold", "LessThanLowerOrGreaterThanUpperThreshold", "LessThanLowerThreshold", "GreaterThanUpperThreshold"
542
583
  # resp.metric_alarms[0].treat_missing_data #=> String
543
584
  # resp.metric_alarms[0].evaluate_low_sample_count_percentile #=> String
544
585
  # resp.metric_alarms[0].metrics #=> Array
@@ -554,6 +595,7 @@ module Aws::CloudWatch
554
595
  # resp.metric_alarms[0].metrics[0].expression #=> String
555
596
  # resp.metric_alarms[0].metrics[0].label #=> String
556
597
  # resp.metric_alarms[0].metrics[0].return_data #=> Boolean
598
+ # resp.metric_alarms[0].threshold_metric_id #=> String
557
599
  #
558
600
  # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DescribeAlarmsForMetric AWS API Documentation
559
601
  #
@@ -564,6 +606,82 @@ module Aws::CloudWatch
564
606
  req.send_request(options)
565
607
  end
566
608
 
609
+ # Lists the anomaly detection models that you have created in your
610
+ # account. You can list all models in your account or filter the results
611
+ # to only the models that are related to a certain namespace, metric
612
+ # name, or metric dimension.
613
+ #
614
+ # @option params [String] :next_token
615
+ # Use the token returned by the previous operation to request the next
616
+ # page of results.
617
+ #
618
+ # @option params [Integer] :max_results
619
+ # The maximum number of results to return in one operation. The maximum
620
+ # value you can specify is 10.
621
+ #
622
+ # To retrieve the remaining results, make another call with the returned
623
+ # `NextToken` value.
624
+ #
625
+ # @option params [String] :namespace
626
+ # Limits the results to only the anomaly detection models that are
627
+ # associated with the specified namespace.
628
+ #
629
+ # @option params [String] :metric_name
630
+ # Limits the results to only the anomaly detection models that are
631
+ # associated with the specified metric name. If there are multiple
632
+ # metrics with this name in different namespaces that have anomaly
633
+ # detection models, they're all returned.
634
+ #
635
+ # @option params [Array<Types::Dimension>] :dimensions
636
+ # Limits the results to only the anomaly detection models that are
637
+ # associated with the specified metric dimensions. If there are multiple
638
+ # metrics that have these dimensions and have anomaly detection models
639
+ # associated, they're all returned.
640
+ #
641
+ # @return [Types::DescribeAnomalyDetectorsOutput] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
642
+ #
643
+ # * {Types::DescribeAnomalyDetectorsOutput#anomaly_detectors #anomaly_detectors} => Array&lt;Types::AnomalyDetector&gt;
644
+ # * {Types::DescribeAnomalyDetectorsOutput#next_token #next_token} => String
645
+ #
646
+ # @example Request syntax with placeholder values
647
+ #
648
+ # resp = client.describe_anomaly_detectors({
649
+ # next_token: "NextToken",
650
+ # max_results: 1,
651
+ # namespace: "Namespace",
652
+ # metric_name: "MetricName",
653
+ # dimensions: [
654
+ # {
655
+ # name: "DimensionName", # required
656
+ # value: "DimensionValue", # required
657
+ # },
658
+ # ],
659
+ # })
660
+ #
661
+ # @example Response structure
662
+ #
663
+ # resp.anomaly_detectors #=> Array
664
+ # resp.anomaly_detectors[0].namespace #=> String
665
+ # resp.anomaly_detectors[0].metric_name #=> String
666
+ # resp.anomaly_detectors[0].dimensions #=> Array
667
+ # resp.anomaly_detectors[0].dimensions[0].name #=> String
668
+ # resp.anomaly_detectors[0].dimensions[0].value #=> String
669
+ # resp.anomaly_detectors[0].stat #=> String
670
+ # resp.anomaly_detectors[0].configuration.excluded_time_ranges #=> Array
671
+ # resp.anomaly_detectors[0].configuration.excluded_time_ranges[0].start_time #=> Time
672
+ # resp.anomaly_detectors[0].configuration.excluded_time_ranges[0].end_time #=> Time
673
+ # resp.anomaly_detectors[0].configuration.metric_timezone #=> String
674
+ # resp.next_token #=> String
675
+ #
676
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DescribeAnomalyDetectors AWS API Documentation
677
+ #
678
+ # @overload describe_anomaly_detectors(params = {})
679
+ # @param [Hash] params ({})
680
+ def describe_anomaly_detectors(params = {}, options = {})
681
+ req = build_request(:describe_anomaly_detectors, params)
682
+ req.send_request(options)
683
+ end
684
+
567
685
  # Disables the actions for the specified alarms. When an alarm's
568
686
  # actions are disabled, the alarm actions do not execute when the alarm
569
687
  # state changes.
@@ -1241,12 +1359,77 @@ module Aws::CloudWatch
1241
1359
  req.send_request(options)
1242
1360
  end
1243
1361
 
1362
+ # Creates an anomaly detection model for a CloudWatch metric. You can
1363
+ # use the model to display a band of expected normal values when the
1364
+ # metric is graphed.
1365
+ #
1366
+ # For more information, see [CloudWatch Anomaly Detection][1].
1367
+ #
1368
+ #
1369
+ #
1370
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Anomaly_Detection.html
1371
+ #
1372
+ # @option params [required, String] :namespace
1373
+ # The namespace of the metric to create the anomaly detection model for.
1374
+ #
1375
+ # @option params [required, String] :metric_name
1376
+ # The name of the metric to create the anomaly detection model for.
1377
+ #
1378
+ # @option params [Array<Types::Dimension>] :dimensions
1379
+ # The metric dimensions to create the anomaly detection model for.
1380
+ #
1381
+ # @option params [required, String] :stat
1382
+ # The statistic to use for the metric and the anomaly detection model.
1383
+ #
1384
+ # @option params [Types::AnomalyDetectorConfiguration] :configuration
1385
+ # The configuration specifies details about how the anomaly detection
1386
+ # model is to be trained, including time ranges to exclude when training
1387
+ # and updating the model. You can specify as many as 10 time ranges.
1388
+ #
1389
+ # The configuration can also include the time zone to use for the
1390
+ # metric.
1391
+ #
1392
+ # You can in
1393
+ #
1394
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
1395
+ #
1396
+ # @example Request syntax with placeholder values
1397
+ #
1398
+ # resp = client.put_anomaly_detector({
1399
+ # namespace: "Namespace", # required
1400
+ # metric_name: "MetricName", # required
1401
+ # dimensions: [
1402
+ # {
1403
+ # name: "DimensionName", # required
1404
+ # value: "DimensionValue", # required
1405
+ # },
1406
+ # ],
1407
+ # stat: "Stat", # required
1408
+ # configuration: {
1409
+ # excluded_time_ranges: [
1410
+ # {
1411
+ # start_time: Time.now, # required
1412
+ # end_time: Time.now, # required
1413
+ # },
1414
+ # ],
1415
+ # metric_timezone: "AnomalyDetectorMetricTimezone",
1416
+ # },
1417
+ # })
1418
+ #
1419
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/PutAnomalyDetector AWS API Documentation
1420
+ #
1421
+ # @overload put_anomaly_detector(params = {})
1422
+ # @param [Hash] params ({})
1423
+ def put_anomaly_detector(params = {}, options = {})
1424
+ req = build_request(:put_anomaly_detector, params)
1425
+ req.send_request(options)
1426
+ end
1427
+
1244
1428
  # Creates a dashboard if it does not already exist, or updates an
1245
1429
  # existing dashboard. If you update a dashboard, the entire contents are
1246
1430
  # replaced with what you specify here.
1247
1431
  #
1248
- # There is no limit to the number of dashboards in your account. All
1249
- # dashboards in your account are global, not region-specific.
1432
+ # All dashboards in your account are global, not region-specific.
1250
1433
  #
1251
1434
  # A simple way to create a dashboard using `PutDashboard` is to copy an
1252
1435
  # existing dashboard. To copy an existing dashboard using the console,
@@ -1305,7 +1488,10 @@ module Aws::CloudWatch
1305
1488
  end
1306
1489
 
1307
1490
  # Creates or updates an alarm and associates it with the specified
1308
- # metric or metric math expression.
1491
+ # metric, metric math expression, or anomaly detection model.
1492
+ #
1493
+ # Alarms based on anomaly detection models cannot have Auto Scaling
1494
+ # actions.
1309
1495
  #
1310
1496
  # When this operation creates an alarm, the alarm state is immediately
1311
1497
  # set to `INSUFFICIENT_DATA`. The alarm is then evaluated and its state
@@ -1508,7 +1694,7 @@ module Aws::CloudWatch
1508
1694
  #
1509
1695
  # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/AlarmThatSendsEmail.html#alarm-evaluation
1510
1696
  #
1511
- # @option params [required, Float] :threshold
1697
+ # @option params [Float] :threshold
1512
1698
  # The value against which the specified statistic is compared.
1513
1699
  #
1514
1700
  # @option params [required, String] :comparison_operator
@@ -1516,6 +1702,10 @@ module Aws::CloudWatch
1516
1702
  # and threshold. The specified statistic value is used as the first
1517
1703
  # operand.
1518
1704
  #
1705
+ # The values `LessThanLowerOrGreaterThanUpperThreshold`,
1706
+ # `LessThanLowerThreshold`, and `GreaterThanUpperThreshold` are used
1707
+ # only for alarms based on anomaly detection models.
1708
+ #
1519
1709
  # @option params [String] :treat_missing_data
1520
1710
  # Sets how this alarm is to handle missing data points. If
1521
1711
  # `TreatMissingData` is omitted, the default behavior of `missing` is
@@ -1568,6 +1758,16 @@ module Aws::CloudWatch
1568
1758
  # use them to scope user permissions, by granting a user permission to
1569
1759
  # access or change only resources with certain tag values.
1570
1760
  #
1761
+ # @option params [String] :threshold_metric_id
1762
+ # If this is an alarm based on an anomaly detection model, make this
1763
+ # value match the ID of the `ANOMALY_DETECTION_BAND` function.
1764
+ #
1765
+ # For an example of how to use this parameter, see the **Anomaly
1766
+ # Detection Model Alarm** example on this page.
1767
+ #
1768
+ # If your alarm uses this parameter, it cannot have Auto Scaling
1769
+ # actions.
1770
+ #
1571
1771
  # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
1572
1772
  #
1573
1773
  # @example Request syntax with placeholder values
@@ -1593,8 +1793,8 @@ module Aws::CloudWatch
1593
1793
  # unit: "Seconds", # accepts Seconds, Microseconds, Milliseconds, Bytes, Kilobytes, Megabytes, Gigabytes, Terabytes, Bits, Kilobits, Megabits, Gigabits, Terabits, Percent, Count, Bytes/Second, Kilobytes/Second, Megabytes/Second, Gigabytes/Second, Terabytes/Second, Bits/Second, Kilobits/Second, Megabits/Second, Gigabits/Second, Terabits/Second, Count/Second, None
1594
1794
  # evaluation_periods: 1, # required
1595
1795
  # datapoints_to_alarm: 1,
1596
- # threshold: 1.0, # required
1597
- # comparison_operator: "GreaterThanOrEqualToThreshold", # required, accepts GreaterThanOrEqualToThreshold, GreaterThanThreshold, LessThanThreshold, LessThanOrEqualToThreshold
1796
+ # threshold: 1.0,
1797
+ # comparison_operator: "GreaterThanOrEqualToThreshold", # required, accepts GreaterThanOrEqualToThreshold, GreaterThanThreshold, LessThanThreshold, LessThanOrEqualToThreshold, LessThanLowerOrGreaterThanUpperThreshold, LessThanLowerThreshold, GreaterThanUpperThreshold
1598
1798
  # treat_missing_data: "TreatMissingData",
1599
1799
  # evaluate_low_sample_count_percentile: "EvaluateLowSampleCountPercentile",
1600
1800
  # metrics: [
@@ -1626,6 +1826,7 @@ module Aws::CloudWatch
1626
1826
  # value: "TagValue", # required
1627
1827
  # },
1628
1828
  # ],
1829
+ # threshold_metric_id: "MetricId",
1629
1830
  # })
1630
1831
  #
1631
1832
  # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/PutMetricAlarm AWS API Documentation
@@ -1879,7 +2080,7 @@ module Aws::CloudWatch
1879
2080
  params: params,
1880
2081
  config: config)
1881
2082
  context[:gem_name] = 'aws-sdk-cloudwatch'
1882
- context[:gem_version] = '1.25.0'
2083
+ context[:gem_version] = '1.26.0'
1883
2084
  Seahorse::Client::Request.new(handlers, context)
1884
2085
  end
1885
2086
 
@@ -21,6 +21,11 @@ module Aws::CloudWatch
21
21
  AlarmNamePrefix = Shapes::StringShape.new(name: 'AlarmNamePrefix')
22
22
  AlarmNames = Shapes::ListShape.new(name: 'AlarmNames')
23
23
  AmazonResourceName = Shapes::StringShape.new(name: 'AmazonResourceName')
24
+ AnomalyDetector = Shapes::StructureShape.new(name: 'AnomalyDetector')
25
+ AnomalyDetectorConfiguration = Shapes::StructureShape.new(name: 'AnomalyDetectorConfiguration')
26
+ AnomalyDetectorExcludedTimeRanges = Shapes::ListShape.new(name: 'AnomalyDetectorExcludedTimeRanges')
27
+ AnomalyDetectorMetricTimezone = Shapes::StringShape.new(name: 'AnomalyDetectorMetricTimezone')
28
+ AnomalyDetectors = Shapes::ListShape.new(name: 'AnomalyDetectors')
24
29
  AwsQueryErrorMessage = Shapes::StringShape.new(name: 'AwsQueryErrorMessage')
25
30
  ComparisonOperator = Shapes::StringShape.new(name: 'ComparisonOperator')
26
31
  ConcurrentModificationException = Shapes::StructureShape.new(name: 'ConcurrentModificationException')
@@ -45,6 +50,8 @@ module Aws::CloudWatch
45
50
  Datapoints = Shapes::ListShape.new(name: 'Datapoints')
46
51
  DatapointsToAlarm = Shapes::IntegerShape.new(name: 'DatapointsToAlarm')
47
52
  DeleteAlarmsInput = Shapes::StructureShape.new(name: 'DeleteAlarmsInput')
53
+ DeleteAnomalyDetectorInput = Shapes::StructureShape.new(name: 'DeleteAnomalyDetectorInput')
54
+ DeleteAnomalyDetectorOutput = Shapes::StructureShape.new(name: 'DeleteAnomalyDetectorOutput')
48
55
  DeleteDashboardsInput = Shapes::StructureShape.new(name: 'DeleteDashboardsInput')
49
56
  DeleteDashboardsOutput = Shapes::StructureShape.new(name: 'DeleteDashboardsOutput')
50
57
  DescribeAlarmHistoryInput = Shapes::StructureShape.new(name: 'DescribeAlarmHistoryInput')
@@ -53,6 +60,8 @@ module Aws::CloudWatch
53
60
  DescribeAlarmsForMetricOutput = Shapes::StructureShape.new(name: 'DescribeAlarmsForMetricOutput')
54
61
  DescribeAlarmsInput = Shapes::StructureShape.new(name: 'DescribeAlarmsInput')
55
62
  DescribeAlarmsOutput = Shapes::StructureShape.new(name: 'DescribeAlarmsOutput')
63
+ DescribeAnomalyDetectorsInput = Shapes::StructureShape.new(name: 'DescribeAnomalyDetectorsInput')
64
+ DescribeAnomalyDetectorsOutput = Shapes::StructureShape.new(name: 'DescribeAnomalyDetectorsOutput')
56
65
  Dimension = Shapes::StructureShape.new(name: 'Dimension')
57
66
  DimensionFilter = Shapes::StructureShape.new(name: 'DimensionFilter')
58
67
  DimensionFilters = Shapes::ListShape.new(name: 'DimensionFilters')
@@ -85,6 +94,7 @@ module Aws::CloudWatch
85
94
  InvalidParameterCombinationException = Shapes::StructureShape.new(name: 'InvalidParameterCombinationException')
86
95
  InvalidParameterValueException = Shapes::StructureShape.new(name: 'InvalidParameterValueException')
87
96
  LastModified = Shapes::TimestampShape.new(name: 'LastModified')
97
+ LimitExceededException = Shapes::StructureShape.new(name: 'LimitExceededException')
88
98
  LimitExceededFault = Shapes::StructureShape.new(name: 'LimitExceededFault')
89
99
  ListDashboardsInput = Shapes::StructureShape.new(name: 'ListDashboardsInput')
90
100
  ListDashboardsOutput = Shapes::StructureShape.new(name: 'ListDashboardsOutput')
@@ -93,6 +103,7 @@ module Aws::CloudWatch
93
103
  ListTagsForResourceInput = Shapes::StructureShape.new(name: 'ListTagsForResourceInput')
94
104
  ListTagsForResourceOutput = Shapes::StructureShape.new(name: 'ListTagsForResourceOutput')
95
105
  MaxRecords = Shapes::IntegerShape.new(name: 'MaxRecords')
106
+ MaxReturnedResultsCount = Shapes::IntegerShape.new(name: 'MaxReturnedResultsCount')
96
107
  Message = Shapes::StringShape.new(name: 'Message')
97
108
  MessageData = Shapes::StructureShape.new(name: 'MessageData')
98
109
  MessageDataCode = Shapes::StringShape.new(name: 'MessageDataCode')
@@ -120,10 +131,13 @@ module Aws::CloudWatch
120
131
  NextToken = Shapes::StringShape.new(name: 'NextToken')
121
132
  OutputFormat = Shapes::StringShape.new(name: 'OutputFormat')
122
133
  Period = Shapes::IntegerShape.new(name: 'Period')
134
+ PutAnomalyDetectorInput = Shapes::StructureShape.new(name: 'PutAnomalyDetectorInput')
135
+ PutAnomalyDetectorOutput = Shapes::StructureShape.new(name: 'PutAnomalyDetectorOutput')
123
136
  PutDashboardInput = Shapes::StructureShape.new(name: 'PutDashboardInput')
124
137
  PutDashboardOutput = Shapes::StructureShape.new(name: 'PutDashboardOutput')
125
138
  PutMetricAlarmInput = Shapes::StructureShape.new(name: 'PutMetricAlarmInput')
126
139
  PutMetricDataInput = Shapes::StructureShape.new(name: 'PutMetricDataInput')
140
+ Range = Shapes::StructureShape.new(name: 'Range')
127
141
  ResourceId = Shapes::StringShape.new(name: 'ResourceId')
128
142
  ResourceList = Shapes::ListShape.new(name: 'ResourceList')
129
143
  ResourceName = Shapes::StringShape.new(name: 'ResourceName')
@@ -170,6 +184,21 @@ module Aws::CloudWatch
170
184
 
171
185
  AlarmNames.member = Shapes::ShapeRef.new(shape: AlarmName)
172
186
 
187
+ AnomalyDetector.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, location_name: "Namespace"))
188
+ AnomalyDetector.add_member(:metric_name, Shapes::ShapeRef.new(shape: MetricName, location_name: "MetricName"))
189
+ AnomalyDetector.add_member(:dimensions, Shapes::ShapeRef.new(shape: Dimensions, location_name: "Dimensions"))
190
+ AnomalyDetector.add_member(:stat, Shapes::ShapeRef.new(shape: Stat, location_name: "Stat"))
191
+ AnomalyDetector.add_member(:configuration, Shapes::ShapeRef.new(shape: AnomalyDetectorConfiguration, location_name: "Configuration"))
192
+ AnomalyDetector.struct_class = Types::AnomalyDetector
193
+
194
+ AnomalyDetectorConfiguration.add_member(:excluded_time_ranges, Shapes::ShapeRef.new(shape: AnomalyDetectorExcludedTimeRanges, location_name: "ExcludedTimeRanges"))
195
+ AnomalyDetectorConfiguration.add_member(:metric_timezone, Shapes::ShapeRef.new(shape: AnomalyDetectorMetricTimezone, location_name: "MetricTimezone"))
196
+ AnomalyDetectorConfiguration.struct_class = Types::AnomalyDetectorConfiguration
197
+
198
+ AnomalyDetectorExcludedTimeRanges.member = Shapes::ShapeRef.new(shape: Range)
199
+
200
+ AnomalyDetectors.member = Shapes::ShapeRef.new(shape: AnomalyDetector)
201
+
173
202
  Counts.member = Shapes::ShapeRef.new(shape: DatapointValue)
174
203
 
175
204
  DashboardEntries.member = Shapes::ShapeRef.new(shape: DashboardEntry)
@@ -215,6 +244,14 @@ module Aws::CloudWatch
215
244
  DeleteAlarmsInput.add_member(:alarm_names, Shapes::ShapeRef.new(shape: AlarmNames, required: true, location_name: "AlarmNames"))
216
245
  DeleteAlarmsInput.struct_class = Types::DeleteAlarmsInput
217
246
 
247
+ DeleteAnomalyDetectorInput.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, required: true, location_name: "Namespace"))
248
+ DeleteAnomalyDetectorInput.add_member(:metric_name, Shapes::ShapeRef.new(shape: MetricName, required: true, location_name: "MetricName"))
249
+ DeleteAnomalyDetectorInput.add_member(:dimensions, Shapes::ShapeRef.new(shape: Dimensions, location_name: "Dimensions"))
250
+ DeleteAnomalyDetectorInput.add_member(:stat, Shapes::ShapeRef.new(shape: Stat, required: true, location_name: "Stat"))
251
+ DeleteAnomalyDetectorInput.struct_class = Types::DeleteAnomalyDetectorInput
252
+
253
+ DeleteAnomalyDetectorOutput.struct_class = Types::DeleteAnomalyDetectorOutput
254
+
218
255
  DeleteDashboardsInput.add_member(:dashboard_names, Shapes::ShapeRef.new(shape: DashboardNames, required: true, location_name: "DashboardNames"))
219
256
  DeleteDashboardsInput.struct_class = Types::DeleteDashboardsInput
220
257
 
@@ -256,6 +293,17 @@ module Aws::CloudWatch
256
293
  DescribeAlarmsOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "NextToken"))
257
294
  DescribeAlarmsOutput.struct_class = Types::DescribeAlarmsOutput
258
295
 
296
+ DescribeAnomalyDetectorsInput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "NextToken"))
297
+ DescribeAnomalyDetectorsInput.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxReturnedResultsCount, location_name: "MaxResults"))
298
+ DescribeAnomalyDetectorsInput.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, location_name: "Namespace"))
299
+ DescribeAnomalyDetectorsInput.add_member(:metric_name, Shapes::ShapeRef.new(shape: MetricName, location_name: "MetricName"))
300
+ DescribeAnomalyDetectorsInput.add_member(:dimensions, Shapes::ShapeRef.new(shape: Dimensions, location_name: "Dimensions"))
301
+ DescribeAnomalyDetectorsInput.struct_class = Types::DescribeAnomalyDetectorsInput
302
+
303
+ DescribeAnomalyDetectorsOutput.add_member(:anomaly_detectors, Shapes::ShapeRef.new(shape: AnomalyDetectors, location_name: "AnomalyDetectors"))
304
+ DescribeAnomalyDetectorsOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "NextToken"))
305
+ DescribeAnomalyDetectorsOutput.struct_class = Types::DescribeAnomalyDetectorsOutput
306
+
259
307
  Dimension.add_member(:name, Shapes::ShapeRef.new(shape: DimensionName, required: true, location_name: "Name"))
260
308
  Dimension.add_member(:value, Shapes::ShapeRef.new(shape: DimensionValue, required: true, location_name: "Value"))
261
309
  Dimension.struct_class = Types::Dimension
@@ -396,6 +444,7 @@ module Aws::CloudWatch
396
444
  MetricAlarm.add_member(:treat_missing_data, Shapes::ShapeRef.new(shape: TreatMissingData, location_name: "TreatMissingData"))
397
445
  MetricAlarm.add_member(:evaluate_low_sample_count_percentile, Shapes::ShapeRef.new(shape: EvaluateLowSampleCountPercentile, location_name: "EvaluateLowSampleCountPercentile"))
398
446
  MetricAlarm.add_member(:metrics, Shapes::ShapeRef.new(shape: MetricDataQueries, location_name: "Metrics"))
447
+ MetricAlarm.add_member(:threshold_metric_id, Shapes::ShapeRef.new(shape: MetricId, location_name: "ThresholdMetricId"))
399
448
  MetricAlarm.struct_class = Types::MetricAlarm
400
449
 
401
450
  MetricAlarms.member = Shapes::ShapeRef.new(shape: MetricAlarm)
@@ -445,6 +494,15 @@ module Aws::CloudWatch
445
494
  MissingRequiredParameterException.add_member(:message, Shapes::ShapeRef.new(shape: AwsQueryErrorMessage, location_name: "message"))
446
495
  MissingRequiredParameterException.struct_class = Types::MissingRequiredParameterException
447
496
 
497
+ PutAnomalyDetectorInput.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, required: true, location_name: "Namespace"))
498
+ PutAnomalyDetectorInput.add_member(:metric_name, Shapes::ShapeRef.new(shape: MetricName, required: true, location_name: "MetricName"))
499
+ PutAnomalyDetectorInput.add_member(:dimensions, Shapes::ShapeRef.new(shape: Dimensions, location_name: "Dimensions"))
500
+ PutAnomalyDetectorInput.add_member(:stat, Shapes::ShapeRef.new(shape: Stat, required: true, location_name: "Stat"))
501
+ PutAnomalyDetectorInput.add_member(:configuration, Shapes::ShapeRef.new(shape: AnomalyDetectorConfiguration, location_name: "Configuration"))
502
+ PutAnomalyDetectorInput.struct_class = Types::PutAnomalyDetectorInput
503
+
504
+ PutAnomalyDetectorOutput.struct_class = Types::PutAnomalyDetectorOutput
505
+
448
506
  PutDashboardInput.add_member(:dashboard_name, Shapes::ShapeRef.new(shape: DashboardName, required: true, location_name: "DashboardName"))
449
507
  PutDashboardInput.add_member(:dashboard_body, Shapes::ShapeRef.new(shape: DashboardBody, required: true, location_name: "DashboardBody"))
450
508
  PutDashboardInput.struct_class = Types::PutDashboardInput
@@ -467,18 +525,23 @@ module Aws::CloudWatch
467
525
  PutMetricAlarmInput.add_member(:unit, Shapes::ShapeRef.new(shape: StandardUnit, location_name: "Unit"))
468
526
  PutMetricAlarmInput.add_member(:evaluation_periods, Shapes::ShapeRef.new(shape: EvaluationPeriods, required: true, location_name: "EvaluationPeriods"))
469
527
  PutMetricAlarmInput.add_member(:datapoints_to_alarm, Shapes::ShapeRef.new(shape: DatapointsToAlarm, location_name: "DatapointsToAlarm"))
470
- PutMetricAlarmInput.add_member(:threshold, Shapes::ShapeRef.new(shape: Threshold, required: true, location_name: "Threshold"))
528
+ PutMetricAlarmInput.add_member(:threshold, Shapes::ShapeRef.new(shape: Threshold, location_name: "Threshold"))
471
529
  PutMetricAlarmInput.add_member(:comparison_operator, Shapes::ShapeRef.new(shape: ComparisonOperator, required: true, location_name: "ComparisonOperator"))
472
530
  PutMetricAlarmInput.add_member(:treat_missing_data, Shapes::ShapeRef.new(shape: TreatMissingData, location_name: "TreatMissingData"))
473
531
  PutMetricAlarmInput.add_member(:evaluate_low_sample_count_percentile, Shapes::ShapeRef.new(shape: EvaluateLowSampleCountPercentile, location_name: "EvaluateLowSampleCountPercentile"))
474
532
  PutMetricAlarmInput.add_member(:metrics, Shapes::ShapeRef.new(shape: MetricDataQueries, location_name: "Metrics"))
475
533
  PutMetricAlarmInput.add_member(:tags, Shapes::ShapeRef.new(shape: TagList, location_name: "Tags"))
534
+ PutMetricAlarmInput.add_member(:threshold_metric_id, Shapes::ShapeRef.new(shape: MetricId, location_name: "ThresholdMetricId"))
476
535
  PutMetricAlarmInput.struct_class = Types::PutMetricAlarmInput
477
536
 
478
537
  PutMetricDataInput.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, required: true, location_name: "Namespace"))
479
538
  PutMetricDataInput.add_member(:metric_data, Shapes::ShapeRef.new(shape: MetricData, required: true, location_name: "MetricData"))
480
539
  PutMetricDataInput.struct_class = Types::PutMetricDataInput
481
540
 
541
+ Range.add_member(:start_time, Shapes::ShapeRef.new(shape: Timestamp, required: true, location_name: "StartTime"))
542
+ Range.add_member(:end_time, Shapes::ShapeRef.new(shape: Timestamp, required: true, location_name: "EndTime"))
543
+ Range.struct_class = Types::Range
544
+
482
545
  ResourceList.member = Shapes::ShapeRef.new(shape: ResourceName)
483
546
 
484
547
  ResourceNotFound.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessage, location_name: "message"))
@@ -553,6 +616,18 @@ module Aws::CloudWatch
553
616
  o.errors << Shapes::ShapeRef.new(shape: ResourceNotFound)
554
617
  end)
555
618
 
619
+ api.add_operation(:delete_anomaly_detector, Seahorse::Model::Operation.new.tap do |o|
620
+ o.name = "DeleteAnomalyDetector"
621
+ o.http_method = "POST"
622
+ o.http_request_uri = "/"
623
+ o.input = Shapes::ShapeRef.new(shape: DeleteAnomalyDetectorInput)
624
+ o.output = Shapes::ShapeRef.new(shape: DeleteAnomalyDetectorOutput)
625
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
626
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceFault)
627
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterValueException)
628
+ o.errors << Shapes::ShapeRef.new(shape: MissingRequiredParameterException)
629
+ end)
630
+
556
631
  api.add_operation(:delete_dashboards, Seahorse::Model::Operation.new.tap do |o|
557
632
  o.name = "DeleteDashboards"
558
633
  o.http_method = "POST"
@@ -602,6 +677,17 @@ module Aws::CloudWatch
602
677
  o.output = Shapes::ShapeRef.new(shape: DescribeAlarmsForMetricOutput)
603
678
  end)
604
679
 
680
+ api.add_operation(:describe_anomaly_detectors, Seahorse::Model::Operation.new.tap do |o|
681
+ o.name = "DescribeAnomalyDetectors"
682
+ o.http_method = "POST"
683
+ o.http_request_uri = "/"
684
+ o.input = Shapes::ShapeRef.new(shape: DescribeAnomalyDetectorsInput)
685
+ o.output = Shapes::ShapeRef.new(shape: DescribeAnomalyDetectorsOutput)
686
+ o.errors << Shapes::ShapeRef.new(shape: InvalidNextToken)
687
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceFault)
688
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterValueException)
689
+ end)
690
+
605
691
  api.add_operation(:disable_alarm_actions, Seahorse::Model::Operation.new.tap do |o|
606
692
  o.name = "DisableAlarmActions"
607
693
  o.http_method = "POST"
@@ -705,6 +791,18 @@ module Aws::CloudWatch
705
791
  o.errors << Shapes::ShapeRef.new(shape: InternalServiceFault)
706
792
  end)
707
793
 
794
+ api.add_operation(:put_anomaly_detector, Seahorse::Model::Operation.new.tap do |o|
795
+ o.name = "PutAnomalyDetector"
796
+ o.http_method = "POST"
797
+ o.http_request_uri = "/"
798
+ o.input = Shapes::ShapeRef.new(shape: PutAnomalyDetectorInput)
799
+ o.output = Shapes::ShapeRef.new(shape: PutAnomalyDetectorOutput)
800
+ o.errors << Shapes::ShapeRef.new(shape: LimitExceededException)
801
+ o.errors << Shapes::ShapeRef.new(shape: InternalServiceFault)
802
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterValueException)
803
+ o.errors << Shapes::ShapeRef.new(shape: MissingRequiredParameterException)
804
+ end)
805
+
708
806
  api.add_operation(:put_dashboard, Seahorse::Model::Operation.new.tap do |o|
709
807
  o.name = "PutDashboard"
710
808
  o.http_method = "POST"
@@ -316,8 +316,8 @@ module Aws::CloudWatch
316
316
  # unit: "Seconds", # accepts Seconds, Microseconds, Milliseconds, Bytes, Kilobytes, Megabytes, Gigabytes, Terabytes, Bits, Kilobits, Megabits, Gigabits, Terabits, Percent, Count, Bytes/Second, Kilobytes/Second, Megabytes/Second, Gigabytes/Second, Terabytes/Second, Bits/Second, Kilobits/Second, Megabits/Second, Gigabits/Second, Terabits/Second, Count/Second, None
317
317
  # evaluation_periods: 1, # required
318
318
  # datapoints_to_alarm: 1,
319
- # threshold: 1.0, # required
320
- # comparison_operator: "GreaterThanOrEqualToThreshold", # required, accepts GreaterThanOrEqualToThreshold, GreaterThanThreshold, LessThanThreshold, LessThanOrEqualToThreshold
319
+ # threshold: 1.0,
320
+ # comparison_operator: "GreaterThanOrEqualToThreshold", # required, accepts GreaterThanOrEqualToThreshold, GreaterThanThreshold, LessThanThreshold, LessThanOrEqualToThreshold, LessThanLowerOrGreaterThanUpperThreshold, LessThanLowerThreshold, GreaterThanUpperThreshold
321
321
  # treat_missing_data: "TreatMissingData",
322
322
  # evaluate_low_sample_count_percentile: "EvaluateLowSampleCountPercentile",
323
323
  # metrics: [
@@ -349,6 +349,7 @@ module Aws::CloudWatch
349
349
  # value: "TagValue", # required
350
350
  # },
351
351
  # ],
352
+ # threshold_metric_id: "MetricId",
352
353
  # })
353
354
  # @param [Hash] options ({})
354
355
  # @option options [required, String] :alarm_name
@@ -481,12 +482,16 @@ module Aws::CloudWatch
481
482
  #
482
483
  #
483
484
  # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/AlarmThatSendsEmail.html#alarm-evaluation
484
- # @option options [required, Float] :threshold
485
+ # @option options [Float] :threshold
485
486
  # The value against which the specified statistic is compared.
486
487
  # @option options [required, String] :comparison_operator
487
488
  # The arithmetic operation to use when comparing the specified statistic
488
489
  # and threshold. The specified statistic value is used as the first
489
490
  # operand.
491
+ #
492
+ # The values `LessThanLowerOrGreaterThanUpperThreshold`,
493
+ # `LessThanLowerThreshold`, and `GreaterThanUpperThreshold` are used
494
+ # only for alarms based on anomaly detection models.
490
495
  # @option options [String] :treat_missing_data
491
496
  # Sets how this alarm is to handle missing data points. If
492
497
  # `TreatMissingData` is omitted, the default behavior of `missing` is
@@ -535,6 +540,15 @@ module Aws::CloudWatch
535
540
  # Tags can help you organize and categorize your resources. You can also
536
541
  # use them to scope user permissions, by granting a user permission to
537
542
  # access or change only resources with certain tag values.
543
+ # @option options [String] :threshold_metric_id
544
+ # If this is an alarm based on an anomaly detection model, make this
545
+ # value match the ID of the `ANOMALY_DETECTION_BAND` function.
546
+ #
547
+ # For an example of how to use this parameter, see the **Anomaly
548
+ # Detection Model Alarm** example on this page.
549
+ #
550
+ # If your alarm uses this parameter, it cannot have Auto Scaling
551
+ # actions.
538
552
  # @return [Alarm]
539
553
  def put_alarm(options = {})
540
554
  options = options.merge(
@@ -41,6 +41,90 @@ module Aws::CloudWatch
41
41
  include Aws::Structure
42
42
  end
43
43
 
44
+ # An anomaly detection model associated with a particular CloudWatch
45
+ # metric athresnd statistic. You can use the model to display a band of
46
+ # expected normal values when the metric is graphed.
47
+ #
48
+ # @!attribute [rw] namespace
49
+ # The namespace of the metric associated with the anomaly detection
50
+ # model.
51
+ # @return [String]
52
+ #
53
+ # @!attribute [rw] metric_name
54
+ # The name of the metric associated with the anomaly detection model.
55
+ # @return [String]
56
+ #
57
+ # @!attribute [rw] dimensions
58
+ # The metric dimensions associated with the anomaly detection model.
59
+ # @return [Array<Types::Dimension>]
60
+ #
61
+ # @!attribute [rw] stat
62
+ # The statistic associated with the anomaly detection model.
63
+ # @return [String]
64
+ #
65
+ # @!attribute [rw] configuration
66
+ # The configuration specifies details about how the anomaly detection
67
+ # model is to be trained, including time ranges to exclude from use
68
+ # for training the model, and the time zone to use for the metric.
69
+ # @return [Types::AnomalyDetectorConfiguration]
70
+ #
71
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/AnomalyDetector AWS API Documentation
72
+ #
73
+ class AnomalyDetector < Struct.new(
74
+ :namespace,
75
+ :metric_name,
76
+ :dimensions,
77
+ :stat,
78
+ :configuration)
79
+ include Aws::Structure
80
+ end
81
+
82
+ # The configuration specifies details about how the anomaly detection
83
+ # model is to be trained, including time ranges to exclude from use for
84
+ # training the model and the time zone to use for the metric.
85
+ #
86
+ # @note When making an API call, you may pass AnomalyDetectorConfiguration
87
+ # data as a hash:
88
+ #
89
+ # {
90
+ # excluded_time_ranges: [
91
+ # {
92
+ # start_time: Time.now, # required
93
+ # end_time: Time.now, # required
94
+ # },
95
+ # ],
96
+ # metric_timezone: "AnomalyDetectorMetricTimezone",
97
+ # }
98
+ #
99
+ # @!attribute [rw] excluded_time_ranges
100
+ # An array of time ranges to exclude from use when the anomaly
101
+ # detection model is trained. Use this to make sure that events that
102
+ # could cause unusual values for the metric, such as deployments,
103
+ # aren't used when CloudWatch creates the model.
104
+ # @return [Array<Types::Range>]
105
+ #
106
+ # @!attribute [rw] metric_timezone
107
+ # The time zone to use for the metric. This is useful to enable the
108
+ # model to automatically account for daylight savings time changes if
109
+ # the metric is sensitive to such time changes.
110
+ #
111
+ # To specify a time zone, use the name of the time zone as specified
112
+ # in the standard tz database. For more information, see [tz
113
+ # database][1].
114
+ #
115
+ #
116
+ #
117
+ # [1]: https://en.wikipedia.org/wiki/Tz_database
118
+ # @return [String]
119
+ #
120
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/AnomalyDetectorConfiguration AWS API Documentation
121
+ #
122
+ class AnomalyDetectorConfiguration < Struct.new(
123
+ :excluded_time_ranges,
124
+ :metric_timezone)
125
+ include Aws::Structure
126
+ end
127
+
44
128
  # Represents a specific dashboard.
45
129
  #
46
130
  # @!attribute [rw] dashboard_name
@@ -185,6 +269,53 @@ module Aws::CloudWatch
185
269
  include Aws::Structure
186
270
  end
187
271
 
272
+ # @note When making an API call, you may pass DeleteAnomalyDetectorInput
273
+ # data as a hash:
274
+ #
275
+ # {
276
+ # namespace: "Namespace", # required
277
+ # metric_name: "MetricName", # required
278
+ # dimensions: [
279
+ # {
280
+ # name: "DimensionName", # required
281
+ # value: "DimensionValue", # required
282
+ # },
283
+ # ],
284
+ # stat: "Stat", # required
285
+ # }
286
+ #
287
+ # @!attribute [rw] namespace
288
+ # The namespace associated with the anomaly detection model to delete.
289
+ # @return [String]
290
+ #
291
+ # @!attribute [rw] metric_name
292
+ # The metric name associated with the anomaly detection model to
293
+ # delete.
294
+ # @return [String]
295
+ #
296
+ # @!attribute [rw] dimensions
297
+ # The metric dimensions associated with the anomaly detection model to
298
+ # delete.
299
+ # @return [Array<Types::Dimension>]
300
+ #
301
+ # @!attribute [rw] stat
302
+ # The statistic associated with the anomaly detection model to delete.
303
+ # @return [String]
304
+ #
305
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DeleteAnomalyDetectorInput AWS API Documentation
306
+ #
307
+ class DeleteAnomalyDetectorInput < Struct.new(
308
+ :namespace,
309
+ :metric_name,
310
+ :dimensions,
311
+ :stat)
312
+ include Aws::Structure
313
+ end
314
+
315
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DeleteAnomalyDetectorOutput AWS API Documentation
316
+ #
317
+ class DeleteAnomalyDetectorOutput < Aws::EmptyStructure; end
318
+
188
319
  # @note When making an API call, you may pass DeleteDashboardsInput
189
320
  # data as a hash:
190
321
  #
@@ -414,6 +545,82 @@ module Aws::CloudWatch
414
545
  include Aws::Structure
415
546
  end
416
547
 
548
+ # @note When making an API call, you may pass DescribeAnomalyDetectorsInput
549
+ # data as a hash:
550
+ #
551
+ # {
552
+ # next_token: "NextToken",
553
+ # max_results: 1,
554
+ # namespace: "Namespace",
555
+ # metric_name: "MetricName",
556
+ # dimensions: [
557
+ # {
558
+ # name: "DimensionName", # required
559
+ # value: "DimensionValue", # required
560
+ # },
561
+ # ],
562
+ # }
563
+ #
564
+ # @!attribute [rw] next_token
565
+ # Use the token returned by the previous operation to request the next
566
+ # page of results.
567
+ # @return [String]
568
+ #
569
+ # @!attribute [rw] max_results
570
+ # The maximum number of results to return in one operation. The
571
+ # maximum value you can specify is 10.
572
+ #
573
+ # To retrieve the remaining results, make another call with the
574
+ # returned `NextToken` value.
575
+ # @return [Integer]
576
+ #
577
+ # @!attribute [rw] namespace
578
+ # Limits the results to only the anomaly detection models that are
579
+ # associated with the specified namespace.
580
+ # @return [String]
581
+ #
582
+ # @!attribute [rw] metric_name
583
+ # Limits the results to only the anomaly detection models that are
584
+ # associated with the specified metric name. If there are multiple
585
+ # metrics with this name in different namespaces that have anomaly
586
+ # detection models, they're all returned.
587
+ # @return [String]
588
+ #
589
+ # @!attribute [rw] dimensions
590
+ # Limits the results to only the anomaly detection models that are
591
+ # associated with the specified metric dimensions. If there are
592
+ # multiple metrics that have these dimensions and have anomaly
593
+ # detection models associated, they're all returned.
594
+ # @return [Array<Types::Dimension>]
595
+ #
596
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DescribeAnomalyDetectorsInput AWS API Documentation
597
+ #
598
+ class DescribeAnomalyDetectorsInput < Struct.new(
599
+ :next_token,
600
+ :max_results,
601
+ :namespace,
602
+ :metric_name,
603
+ :dimensions)
604
+ include Aws::Structure
605
+ end
606
+
607
+ # @!attribute [rw] anomaly_detectors
608
+ # The list of anomaly detection models returned by the operation.
609
+ # @return [Array<Types::AnomalyDetector>]
610
+ #
611
+ # @!attribute [rw] next_token
612
+ # A token that you can use in a subsequent operation to retrieve the
613
+ # next set of results.
614
+ # @return [String]
615
+ #
616
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/DescribeAnomalyDetectorsOutput AWS API Documentation
617
+ #
618
+ class DescribeAnomalyDetectorsOutput < Struct.new(
619
+ :anomaly_detectors,
620
+ :next_token)
621
+ include Aws::Structure
622
+ end
623
+
417
624
  # Expands the identity of a metric.
418
625
  #
419
626
  # @note When making an API call, you may pass Dimension
@@ -1232,7 +1439,8 @@ module Aws::CloudWatch
1232
1439
  # @return [Time]
1233
1440
  #
1234
1441
  # @!attribute [rw] metric_name
1235
- # The name of the metric associated with the alarm.
1442
+ # The name of the metric associated with the alarm, if this is an
1443
+ # alarm based on a single metric.
1236
1444
  # @return [String]
1237
1445
  #
1238
1446
  # @!attribute [rw] namespace
@@ -1295,8 +1503,19 @@ module Aws::CloudWatch
1295
1503
  # @return [String]
1296
1504
  #
1297
1505
  # @!attribute [rw] metrics
1506
+ # An array of MetricDataQuery structures, used in an alarm based on a
1507
+ # metric math expression. Each structure either retrieves a metric or
1508
+ # performs a math expression. One item in the Metrics array is the
1509
+ # math expression that the alarm watches. This expression by
1510
+ # designated by having `ReturnValue` set to true.
1298
1511
  # @return [Array<Types::MetricDataQuery>]
1299
1512
  #
1513
+ # @!attribute [rw] threshold_metric_id
1514
+ # In an alarm based on an anomaly detection model, this is the ID of
1515
+ # the `ANOMALY_DETECTION_BAND` function used as the threshold for the
1516
+ # alarm.
1517
+ # @return [String]
1518
+ #
1300
1519
  # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/MetricAlarm AWS API Documentation
1301
1520
  #
1302
1521
  class MetricAlarm < Struct.new(
@@ -1325,7 +1544,8 @@ module Aws::CloudWatch
1325
1544
  :comparison_operator,
1326
1545
  :treat_missing_data,
1327
1546
  :evaluate_low_sample_count_percentile,
1328
- :metrics)
1547
+ :metrics,
1548
+ :threshold_metric_id)
1329
1549
  include Aws::Structure
1330
1550
  end
1331
1551
 
@@ -1588,7 +1808,9 @@ module Aws::CloudWatch
1588
1808
  # @return [Array<Float>]
1589
1809
  #
1590
1810
  # @!attribute [rw] unit
1591
- # The unit of the metric.
1811
+ # When you are using a `Put` operation, this defines what unit you
1812
+ # want to use when storing the metric. In a `Get` operation, this
1813
+ # displays the unit that is used for the metric.
1592
1814
  # @return [String]
1593
1815
  #
1594
1816
  # @!attribute [rw] storage_resolution
@@ -1661,7 +1883,9 @@ module Aws::CloudWatch
1661
1883
  # @return [String]
1662
1884
  #
1663
1885
  # @!attribute [rw] unit
1664
- # The unit to use for the returned data points.
1886
+ # When you are using a `Put` operation, this defines what unit you
1887
+ # want to use when storing the metric. In a `Get` operation, this
1888
+ # displays the unit that is used for the metric.
1665
1889
  # @return [String]
1666
1890
  #
1667
1891
  # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/MetricStat AWS API Documentation
@@ -1686,6 +1910,74 @@ module Aws::CloudWatch
1686
1910
  include Aws::Structure
1687
1911
  end
1688
1912
 
1913
+ # @note When making an API call, you may pass PutAnomalyDetectorInput
1914
+ # data as a hash:
1915
+ #
1916
+ # {
1917
+ # namespace: "Namespace", # required
1918
+ # metric_name: "MetricName", # required
1919
+ # dimensions: [
1920
+ # {
1921
+ # name: "DimensionName", # required
1922
+ # value: "DimensionValue", # required
1923
+ # },
1924
+ # ],
1925
+ # stat: "Stat", # required
1926
+ # configuration: {
1927
+ # excluded_time_ranges: [
1928
+ # {
1929
+ # start_time: Time.now, # required
1930
+ # end_time: Time.now, # required
1931
+ # },
1932
+ # ],
1933
+ # metric_timezone: "AnomalyDetectorMetricTimezone",
1934
+ # },
1935
+ # }
1936
+ #
1937
+ # @!attribute [rw] namespace
1938
+ # The namespace of the metric to create the anomaly detection model
1939
+ # for.
1940
+ # @return [String]
1941
+ #
1942
+ # @!attribute [rw] metric_name
1943
+ # The name of the metric to create the anomaly detection model for.
1944
+ # @return [String]
1945
+ #
1946
+ # @!attribute [rw] dimensions
1947
+ # The metric dimensions to create the anomaly detection model for.
1948
+ # @return [Array<Types::Dimension>]
1949
+ #
1950
+ # @!attribute [rw] stat
1951
+ # The statistic to use for the metric and the anomaly detection model.
1952
+ # @return [String]
1953
+ #
1954
+ # @!attribute [rw] configuration
1955
+ # The configuration specifies details about how the anomaly detection
1956
+ # model is to be trained, including time ranges to exclude when
1957
+ # training and updating the model. You can specify as many as 10 time
1958
+ # ranges.
1959
+ #
1960
+ # The configuration can also include the time zone to use for the
1961
+ # metric.
1962
+ #
1963
+ # You can in
1964
+ # @return [Types::AnomalyDetectorConfiguration]
1965
+ #
1966
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/PutAnomalyDetectorInput AWS API Documentation
1967
+ #
1968
+ class PutAnomalyDetectorInput < Struct.new(
1969
+ :namespace,
1970
+ :metric_name,
1971
+ :dimensions,
1972
+ :stat,
1973
+ :configuration)
1974
+ include Aws::Structure
1975
+ end
1976
+
1977
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/PutAnomalyDetectorOutput AWS API Documentation
1978
+ #
1979
+ class PutAnomalyDetectorOutput < Aws::EmptyStructure; end
1980
+
1689
1981
  # @note When making an API call, you may pass PutDashboardInput
1690
1982
  # data as a hash:
1691
1983
  #
@@ -1762,8 +2054,8 @@ module Aws::CloudWatch
1762
2054
  # unit: "Seconds", # accepts Seconds, Microseconds, Milliseconds, Bytes, Kilobytes, Megabytes, Gigabytes, Terabytes, Bits, Kilobits, Megabits, Gigabits, Terabits, Percent, Count, Bytes/Second, Kilobytes/Second, Megabytes/Second, Gigabytes/Second, Terabytes/Second, Bits/Second, Kilobits/Second, Megabits/Second, Gigabits/Second, Terabits/Second, Count/Second, None
1763
2055
  # evaluation_periods: 1, # required
1764
2056
  # datapoints_to_alarm: 1,
1765
- # threshold: 1.0, # required
1766
- # comparison_operator: "GreaterThanOrEqualToThreshold", # required, accepts GreaterThanOrEqualToThreshold, GreaterThanThreshold, LessThanThreshold, LessThanOrEqualToThreshold
2057
+ # threshold: 1.0,
2058
+ # comparison_operator: "GreaterThanOrEqualToThreshold", # required, accepts GreaterThanOrEqualToThreshold, GreaterThanThreshold, LessThanThreshold, LessThanOrEqualToThreshold, LessThanLowerOrGreaterThanUpperThreshold, LessThanLowerThreshold, GreaterThanUpperThreshold
1767
2059
  # treat_missing_data: "TreatMissingData",
1768
2060
  # evaluate_low_sample_count_percentile: "EvaluateLowSampleCountPercentile",
1769
2061
  # metrics: [
@@ -1795,6 +2087,7 @@ module Aws::CloudWatch
1795
2087
  # value: "TagValue", # required
1796
2088
  # },
1797
2089
  # ],
2090
+ # threshold_metric_id: "MetricId",
1798
2091
  # }
1799
2092
  #
1800
2093
  # @!attribute [rw] alarm_name
@@ -1975,6 +2268,10 @@ module Aws::CloudWatch
1975
2268
  # The arithmetic operation to use when comparing the specified
1976
2269
  # statistic and threshold. The specified statistic value is used as
1977
2270
  # the first operand.
2271
+ #
2272
+ # The values `LessThanLowerOrGreaterThanUpperThreshold`,
2273
+ # `LessThanLowerThreshold`, and `GreaterThanUpperThreshold` are used
2274
+ # only for alarms based on anomaly detection models.
1978
2275
  # @return [String]
1979
2276
  #
1980
2277
  # @!attribute [rw] treat_missing_data
@@ -2034,6 +2331,17 @@ module Aws::CloudWatch
2034
2331
  # values.
2035
2332
  # @return [Array<Types::Tag>]
2036
2333
  #
2334
+ # @!attribute [rw] threshold_metric_id
2335
+ # If this is an alarm based on an anomaly detection model, make this
2336
+ # value match the ID of the `ANOMALY_DETECTION_BAND` function.
2337
+ #
2338
+ # For an example of how to use this parameter, see the **Anomaly
2339
+ # Detection Model Alarm** example on this page.
2340
+ #
2341
+ # If your alarm uses this parameter, it cannot have Auto Scaling
2342
+ # actions.
2343
+ # @return [String]
2344
+ #
2037
2345
  # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/PutMetricAlarmInput AWS API Documentation
2038
2346
  #
2039
2347
  class PutMetricAlarmInput < Struct.new(
@@ -2057,7 +2365,8 @@ module Aws::CloudWatch
2057
2365
  :treat_missing_data,
2058
2366
  :evaluate_low_sample_count_percentile,
2059
2367
  :metrics,
2060
- :tags)
2368
+ :tags,
2369
+ :threshold_metric_id)
2061
2370
  include Aws::Structure
2062
2371
  end
2063
2372
 
@@ -2112,6 +2421,35 @@ module Aws::CloudWatch
2112
2421
  include Aws::Structure
2113
2422
  end
2114
2423
 
2424
+ # Specifies one range of days or times to exclude from use for training
2425
+ # an anomaly detection model.
2426
+ #
2427
+ # @note When making an API call, you may pass Range
2428
+ # data as a hash:
2429
+ #
2430
+ # {
2431
+ # start_time: Time.now, # required
2432
+ # end_time: Time.now, # required
2433
+ # }
2434
+ #
2435
+ # @!attribute [rw] start_time
2436
+ # The start time of the range to exclude. The format is
2437
+ # `yyyy-MM-dd'T'HH:mm:ss`. For example, `2019-07-01T23:59:59`.
2438
+ # @return [Time]
2439
+ #
2440
+ # @!attribute [rw] end_time
2441
+ # The end time of the range to exclude. The format is
2442
+ # `yyyy-MM-dd'T'HH:mm:ss`. For example, `2019-07-01T23:59:59`.
2443
+ # @return [Time]
2444
+ #
2445
+ # @see http://docs.aws.amazon.com/goto/WebAPI/monitoring-2010-08-01/Range AWS API Documentation
2446
+ #
2447
+ class Range < Struct.new(
2448
+ :start_time,
2449
+ :end_time)
2450
+ include Aws::Structure
2451
+ end
2452
+
2115
2453
  # The named resource does not exist.
2116
2454
  #
2117
2455
  # @!attribute [rw] message
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-cloudwatch
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.25.0
4
+ version: 1.26.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-07-01 00:00:00.000000000 Z
11
+ date: 2019-07-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core