import * as cdk from '@aws-cdk/core'; import { DatadogAlertType } from './datadogMonitor'; /** * @stability stable */ export interface DatadogLogIndexMonitoringProps { /** * The name of your service in Datadog. * * Can be used to query the monitors. * * @stability stable */ readonly serviceName: string; /** * The name of the Datadog index. * * @stability stable */ readonly indexName: string; /** * The integration to use for alerting. * * For OpsGenie, you need to install and configure the 'opsgenie-integration' account module. * * @stability stable */ readonly alertType: DatadogAlertType; /** * The daily log quota settings. * * @stability stable */ readonly dailyLogQuota: DatadogLogQuotaProps; /** * This value should be used if there is no log message within 24 hours or missing historical data. * * Without setting this value it will lead to an empty result and therefore trigger an alert. * * @default - false * @stability stable */ readonly sparseLogging?: boolean; } /** * @stability stable */ export interface DatadogLogQuotaProps { /** * The daily log quota for the team-specific index in million events. * * @stability stable */ readonly valueInMillionEvents: number; /** * The warning threshold for the daily log quota monitor in percent. * * @stability stable */ readonly warningThresholdInPercent: number; /** * The alarm threshold for the daily log quota monitor in percent. * * The value must be between 0 and 100 and greater than or equal to the warning threshold. * * @stability stable */ readonly alertThresholdInPercent: number; } /** * Basic monitoring and alerting for a Datadog logs index. * * It follows the Datadog guide at https://docs.datadoghq.com/logs/guide/logs-monitors-on-volumes/ * and consists of the following three monitors. * 1. A metric alert that fires when you reach a certain threshold of your daily log quota. * 2. An anomaly monitor that detects log amount spikes. * 3. An event alert that fires when you hit the daily log quota. * * A datadog log index is team specific and thus the monitor needs to be deployed just once per index/team. * * @stability stable */ export declare class DatadogLogIndexMonitoring extends cdk.Construct { /** * @stability stable */ constructor(scope: cdk.Construct, id: string, props: DatadogLogIndexMonitoringProps); }