Skip to content

CustomizedMetricSpecification

Source code in docs_src/capo_auto_scaling/types/customized_metric_specification.py
class CustomizedMetricSpecification(TypedDict, closed=True):
    metric_name: NotRequired["capo_auto_scaling.types.metric_name.MetricName"]
    """<p>The name of the metric. To get the exact metric name, namespace, and dimensions, inspect the <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_Metric.html">Metric</a> object that is returned by a call to <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_ListMetrics.html">ListMetrics</a>.</p>"""
    namespace: NotRequired["capo_auto_scaling.types.metric_namespace.MetricNamespace"]
    """<p>The namespace of the metric.</p>"""
    dimensions: NotRequired[
        "capo_auto_scaling.types.metric_dimensions.MetricDimensions"
    ]
    """<p>The dimensions of the metric.</p> <p>Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.</p>"""
    statistic: NotRequired["capo_auto_scaling.types.metric_statistic.MetricStatistic"]
    """<p>The statistic of the metric.</p>"""
    unit: NotRequired["capo_auto_scaling.types.metric_unit.MetricUnit"]
    """<p>The unit of the metric. For a complete list of the units that CloudWatch supports, see the <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_MetricDatum.html">MetricDatum</a> data type in the <i>Amazon CloudWatch API Reference</i>.</p>"""
    period: NotRequired[
        "capo_auto_scaling.types.metric_granularity_in_seconds.MetricGranularityInSeconds"
    ]
    """<p> The period of the metric in seconds. The default value is 60. Accepted values are 10, 30, and 60. For high resolution metric, set the value to less than 60. For more information, see <a href="https://docs.aws.amazon.com/autoscaling/ec2/userguide/policy-creating-high-resolution-metrics.html">Create a target tracking policy using high-resolution metrics for faster response</a>. </p>"""
    metrics: NotRequired[
        "capo_auto_scaling.types.target_tracking_metric_data_queries.TargetTrackingMetricDataQueries"
    ]
    """<p>The metrics to include in the target tracking scaling policy, as a metric data query. This can include both raw metric and metric math expressions.</p>"""

dimensions instance-attribute

dimensions: NotRequired[MetricDimensions]

The dimensions of the metric.

Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.

metric_name instance-attribute

metric_name: NotRequired[MetricName]

The name of the metric. To get the exact metric name, namespace, and dimensions, inspect the Metric object that is returned by a call to ListMetrics.

metrics instance-attribute

metrics: NotRequired[TargetTrackingMetricDataQueries]

The metrics to include in the target tracking scaling policy, as a metric data query. This can include both raw metric and metric math expressions.

namespace instance-attribute

namespace: NotRequired[MetricNamespace]

The namespace of the metric.

period instance-attribute

period: NotRequired[MetricGranularityInSeconds]

The period of the metric in seconds. The default value is 60. Accepted values are 10, 30, and 60. For high resolution metric, set the value to less than 60. For more information, see Create a target tracking policy using high-resolution metrics for faster response.

statistic instance-attribute

statistic: NotRequired[MetricStatistic]

The statistic of the metric.

unit instance-attribute

unit: NotRequired[MetricUnit]

The unit of the metric. For a complete list of the units that CloudWatch supports, see the MetricDatum data type in the Amazon CloudWatch API Reference.