resource “aws_cloudwatch_metric_alarm” “xfusion_kinesis_alarm” {
alarm_name = “xfusion-kinesis-alarm”
comparison_operator = “GreaterThanThreshold”
evaluation_periods = 1
metric_name = “WriteProvisionedThroughputExceeded”
namespace = “AWS/Kinesis”
period = 60
statistic = “Sum”
threshold = 1
alarm_description = “Alarm when write throughput exceeds provisioned limit”
dimensions = {
StreamName = aws_kinesis_stream.xfusion_stream.name
}
treat_missing_data = “notBreaching”
}
output “kke_kinesis_stream_name” {
description = “The name of the Kinesis stream”
value = aws_kinesis_stream.devops_stream.name
}
output “kke_kinesis_alarm_name” {
description = “The name of the CloudWatch alarm”
value = aws_cloudwatch_metric_alarm.devops_kinesis_alarm.alarm_name
}