interface MetricProperty
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.CloudWatch.CfnAlarm.MetricProperty |
![]() | github.com/aws/aws-cdk-go/awscdk/v2/awscloudwatch#CfnAlarm_MetricProperty |
![]() | software.amazon.awscdk.services.cloudwatch.CfnAlarm.MetricProperty |
![]() | aws_cdk.aws_cloudwatch.CfnAlarm.MetricProperty |
![]() | aws-cdk-lib » aws_cloudwatch » CfnAlarm » MetricProperty |
The Metric
property type represents a specific metric.
Metric
is a property of the MetricStat property type.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_cloudwatch as cloudwatch } from 'aws-cdk-lib';
const metricProperty: cloudwatch.CfnAlarm.MetricProperty = {
dimensions: [{
name: 'name',
value: 'value',
}],
metricName: 'metricName',
namespace: 'namespace',
};
Properties
Name | Type | Description |
---|---|---|
dimensions? | IResolvable | IResolvable | Dimension [] | The metric dimensions that you want to be used for the metric that the alarm will watch. |
metric | string | The name of the metric that you want the alarm to watch. |
namespace? | string | The namespace of the metric that the alarm will watch. |
dimensions?
Type:
IResolvable
|
IResolvable
|
Dimension
[]
(optional)
The metric dimensions that you want to be used for the metric that the alarm will watch.
metricName?
Type:
string
(optional)
The name of the metric that you want the alarm to watch.
This is a required field.
namespace?
Type:
string
(optional)
The namespace of the metric that the alarm will watch.