Class: Aws::CloudWatch::Types::PutAnomalyDetectorInput

Inherits:
Struct
  • Object
show all
Defined in:
gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb

Overview

Note:

When making an API call, you may pass PutAnomalyDetectorInput data as a hash:

{
  namespace: "Namespace",
  metric_name: "MetricName",
  dimensions: [
    {
      name: "DimensionName", # required
      value: "DimensionValue", # required
    },
  ],
  stat: "AnomalyDetectorMetricStat",
  configuration: {
    excluded_time_ranges: [
      {
        start_time: Time.now, # required
        end_time: Time.now, # required
      },
    ],
    metric_timezone: "AnomalyDetectorMetricTimezone",
  },
  single_metric_anomaly_detector: {
    namespace: "Namespace",
    metric_name: "MetricName",
    dimensions: [
      {
        name: "DimensionName", # required
        value: "DimensionValue", # required
      },
    ],
    stat: "AnomalyDetectorMetricStat",
  },
  metric_math_anomaly_detector: {
    metric_data_queries: [
      {
        id: "MetricId", # required
        metric_stat: {
          metric: { # required
            namespace: "Namespace",
            metric_name: "MetricName",
            dimensions: [
              {
                name: "DimensionName", # required
                value: "DimensionValue", # required
              },
            ],
          },
          period: 1, # required
          stat: "Stat", # required
          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
        },
        expression: "MetricExpression",
        label: "MetricLabel",
        return_data: false,
        period: 1,
        account_id: "AccountId",
      },
    ],
  },
}

Constant Summary collapse

SENSITIVE =
[]

Instance Attribute Summary collapse

Instance Attribute Details

#configurationTypes::AnomalyDetectorConfiguration

The configuration specifies details about how the anomaly detection model is to be trained, including time ranges to exclude when training and updating the model. You can specify as many as 10 time ranges.

The configuration can also include the time zone to use for the metric.



3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end

#dimensionsArray<Types::Dimension>

The metric dimensions to create the anomaly detection model for.

Returns:



3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end

#metric_math_anomaly_detectorTypes::MetricMathAnomalyDetector

The metric math anomaly detector to be created.

When using MetricMathAnomalyDetector, you cannot include the following parameters in the same operation:

  • Dimensions

  • MetricName

  • Namespace

  • Stat

  • the SingleMetricAnomalyDetector parameters of PutAnomalyDetectorInput

Instead, specify the metric math anomaly detector attributes as part of the property MetricMathAnomalyDetector.



3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end

#metric_nameString

The name of the metric to create the anomaly detection model for.

Returns:

  • (String)


3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end

#namespaceString

The namespace of the metric to create the anomaly detection model for.

Returns:

  • (String)


3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end

#single_metric_anomaly_detectorTypes::SingleMetricAnomalyDetector

A single metric anomaly detector to be created.

When using SingleMetricAnomalyDetector, you cannot include the following parameters in the same operation:

  • Dimensions

  • MetricName

  • Namespace

  • Stat

  • the MetricMatchAnomalyDetector parameters of PutAnomalyDetectorInput

Instead, specify the single metric anomaly detector attributes as part of the property SingleMetricAnomalyDetector.



3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end

#statString

The statistic to use for the metric and the anomaly detection model.

Returns:

  • (String)


3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
# File 'gems/aws-sdk-cloudwatch/lib/aws-sdk-cloudwatch/types.rb', line 3495

class PutAnomalyDetectorInput < Struct.new(
  :namespace,
  :metric_name,
  :dimensions,
  :stat,
  :configuration,
  :single_metric_anomaly_detector,
  :metric_math_anomaly_detector)
  SENSITIVE = []
  include Aws::Structure
end