TargetTrackingScaling Cloudwatch警报缺少AWS中的数据处理

时间:2019-07-17 01:42:54

标签: terraform terraform-provider-aws

我无法通过Terraform修改AWS中针对TargetTrackingScaling策略类型自动创建的Cloudwatch警报。

我创建了资源 below.

This code works perfectly. It will automatically create 2 alarms (High and Low). However, I noticed that the alarms (specifically the "Low" alarms will be treated as "alarm" because it doesn't have a data yet (missing data). How can I update "missing data treatment" and have it 'none breaching' via terraform?

resource "aws_autoscaling_policy" "my_autoscale_policy" {
name = "my-auto-scale-policy"
autoscaling_group_name = "${aws_autoscaling_group.my_autoscaling.name}"
policy_type            = "TargetTrackingScaling"
target_tracking_configuration {
customized_metric_specification {
    metric_dimension {
        name = "QueueName"
        value = "${aws_sqs_queue.my_sqs.name}"}

  metric_name = "ApproximateNumberOfMessagesVisible"
  namespace = "AWS/SQS"
  statistic = "Maximum"
}

target_value = "5" } }

预期:我将能够像下面的代码一样进行更新。

treat_missing_data =“未突破”

0 个答案:

没有答案