ComparisonOperator

class aws_cdk.aws_cloudwatch.ComparisonOperator(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)

Bases: Enum

Comparison operator for evaluating alarms.

ExampleMetadata:

infused

Example:

import aws_cdk.aws_cloudwatch as cloudwatch

# my_hosted_zone: route53.HostedZone

certificate = acm.Certificate(self, "Certificate",
    domain_name="hello.example.com",
    validation=acm.CertificateValidation.from_dns(my_hosted_zone)
)
certificate.metric_days_to_expiry().create_alarm(self, "Alarm",
    comparison_operator=cloudwatch.ComparisonOperator.LESS_THAN_THRESHOLD,
    evaluation_periods=1,
    threshold=45
)

Attributes

GREATER_THAN_OR_EQUAL_TO_THRESHOLD

Specified statistic is greater than or equal to the threshold.

GREATER_THAN_THRESHOLD

Specified statistic is strictly greater than the threshold.

GREATER_THAN_UPPER_THRESHOLD

Specified statistic is greater than the anomaly model band.

Used only for alarms based on anomaly detection models

LESS_THAN_LOWER_OR_GREATER_THAN_UPPER_THRESHOLD

Specified statistic is lower than or greater than the anomaly model band.

Used only for alarms based on anomaly detection models

LESS_THAN_LOWER_THRESHOLD

Specified statistic is lower than the anomaly model band.

Used only for alarms based on anomaly detection models

LESS_THAN_OR_EQUAL_TO_THRESHOLD

Specified statistic is less than or equal to the threshold.

LESS_THAN_THRESHOLD

Specified statistic is strictly less than the threshold.