UNPKG

cdk-monitoring-constructs

Version:

[![NPM version](https://badge.fury.io/js/cdk-monitoring-constructs.svg)](https://badge.fury.io/js/cdk-monitoring-constructs) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/io.github.cdklabs/cdkmonitoringconstructs/badge.svg)](https://m

31 lines (30 loc) 940 B
import { IAlarmActionStrategy } from "./action"; export interface AlarmNamingInput { readonly action?: IAlarmActionStrategy; readonly alarmNameSuffix: string; readonly alarmNameOverride?: string; readonly alarmDedupeStringSuffix?: string; readonly dedupeStringOverride?: string; readonly disambiguator?: string; } /** * Strategy used to name alarms, their widgets, and their dedupe strings. */ export interface IAlarmNamingStrategy { /** * How to generate the name of an alarm. * * @param props AlarmNamingInput */ getName(props: AlarmNamingInput): string; /** * How to generate the label for the alarm displayed on a widget. * * @param props AlarmNamingInput */ getWidgetLabel(props: AlarmNamingInput): string; /** * How to generate the deduplication string for an alarm. */ getDedupeString(props: AlarmNamingInput): string | undefined; }