"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.CloudfrontLatencyWidget = void 0;
const aws_cdk_lib_1 = require("aws-cdk-lib");
const metrics_1 = require("../../metrics");
class CloudfrontLatencyWidget extends aws_cdk_lib_1.aws_cloudwatch.GraphWidget {
    constructor(props) {
        const { distributionId } = props;
        super({
            title: 'Cache Miss Latency',
            width: 24,
            height: 4,
            left: [new metrics_1.CloudfrontLatencyMetric({ distributionId }, 95)],
            right: [new metrics_1.CloudfrontCacheMissesMetric({ distributionId })],
        });
    }
}
exports.CloudfrontLatencyWidget = CloudfrontLatencyWidget;
