UNPKG

@pulumi/databricks

Version:

A Pulumi package for creating and managing databricks cloud resources.

198 lines (197 loc) 8.25 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "./types/input"; import * as outputs from "./types/output"; /** * ## Import * * This resource can be imported using alert ID: * * bash * * ```sh * $ pulumi import databricks:index/alert:Alert this <alert-id> * ``` */ export declare class Alert extends pulumi.CustomResource { /** * Get an existing Alert resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: AlertState, opts?: pulumi.CustomResourceOptions): Alert; /** * Returns true if the given object is an instance of Alert. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is Alert; /** * Trigger conditions of the alert. Block consists of the following attributes: */ readonly condition: pulumi.Output<outputs.AlertCondition>; /** * The timestamp string indicating when the alert was created. */ readonly createTime: pulumi.Output<string>; /** * Custom body of alert notification, if it exists. See [Alerts API reference](https://docs.databricks.com/en/sql/user/alerts/index.html) for custom templating instructions. */ readonly customBody: pulumi.Output<string | undefined>; /** * Custom subject of alert notification, if it exists. This includes email subject, Slack notification header, etc. See [Alerts API reference](https://docs.databricks.com/en/sql/user/alerts/index.html) for custom templating instructions. */ readonly customSubject: pulumi.Output<string | undefined>; /** * Name of the alert. */ readonly displayName: pulumi.Output<string>; /** * The workspace state of the alert. Used for tracking trashed status. (Possible values are `ACTIVE` or `TRASHED`). */ readonly lifecycleState: pulumi.Output<string>; /** * Whether to notify alert subscribers when alert returns back to normal. */ readonly notifyOnOk: pulumi.Output<boolean | undefined>; /** * Alert owner's username. */ readonly ownerUserName: pulumi.Output<string | undefined>; /** * The path to a workspace folder containing the alert. The default is the user's home folder. If changed, the alert will be recreated. */ readonly parentPath: pulumi.Output<string | undefined>; /** * ID of the query evaluated by the alert. */ readonly queryId: pulumi.Output<string>; /** * Number of seconds an alert must wait after being triggered to rearm itself. After rearming, it can be triggered again. If 0 or not specified, the alert will not be triggered again. */ readonly secondsToRetrigger: pulumi.Output<number | undefined>; /** * Current state of the alert's trigger status (`UNKNOWN`, `OK`, `TRIGGERED`). This field is set to `UNKNOWN` if the alert has not yet been evaluated or ran into an error during the last evaluation. */ readonly state: pulumi.Output<string>; /** * The timestamp string when the alert was last triggered if the alert has been triggered before. */ readonly triggerTime: pulumi.Output<string>; /** * The timestamp string indicating when the alert was updated. */ readonly updateTime: pulumi.Output<string>; /** * Create a Alert resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: AlertArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Alert resources. */ export interface AlertState { /** * Trigger conditions of the alert. Block consists of the following attributes: */ condition?: pulumi.Input<inputs.AlertCondition>; /** * The timestamp string indicating when the alert was created. */ createTime?: pulumi.Input<string>; /** * Custom body of alert notification, if it exists. See [Alerts API reference](https://docs.databricks.com/en/sql/user/alerts/index.html) for custom templating instructions. */ customBody?: pulumi.Input<string>; /** * Custom subject of alert notification, if it exists. This includes email subject, Slack notification header, etc. See [Alerts API reference](https://docs.databricks.com/en/sql/user/alerts/index.html) for custom templating instructions. */ customSubject?: pulumi.Input<string>; /** * Name of the alert. */ displayName?: pulumi.Input<string>; /** * The workspace state of the alert. Used for tracking trashed status. (Possible values are `ACTIVE` or `TRASHED`). */ lifecycleState?: pulumi.Input<string>; /** * Whether to notify alert subscribers when alert returns back to normal. */ notifyOnOk?: pulumi.Input<boolean>; /** * Alert owner's username. */ ownerUserName?: pulumi.Input<string>; /** * The path to a workspace folder containing the alert. The default is the user's home folder. If changed, the alert will be recreated. */ parentPath?: pulumi.Input<string>; /** * ID of the query evaluated by the alert. */ queryId?: pulumi.Input<string>; /** * Number of seconds an alert must wait after being triggered to rearm itself. After rearming, it can be triggered again. If 0 or not specified, the alert will not be triggered again. */ secondsToRetrigger?: pulumi.Input<number>; /** * Current state of the alert's trigger status (`UNKNOWN`, `OK`, `TRIGGERED`). This field is set to `UNKNOWN` if the alert has not yet been evaluated or ran into an error during the last evaluation. */ state?: pulumi.Input<string>; /** * The timestamp string when the alert was last triggered if the alert has been triggered before. */ triggerTime?: pulumi.Input<string>; /** * The timestamp string indicating when the alert was updated. */ updateTime?: pulumi.Input<string>; } /** * The set of arguments for constructing a Alert resource. */ export interface AlertArgs { /** * Trigger conditions of the alert. Block consists of the following attributes: */ condition: pulumi.Input<inputs.AlertCondition>; /** * Custom body of alert notification, if it exists. See [Alerts API reference](https://docs.databricks.com/en/sql/user/alerts/index.html) for custom templating instructions. */ customBody?: pulumi.Input<string>; /** * Custom subject of alert notification, if it exists. This includes email subject, Slack notification header, etc. See [Alerts API reference](https://docs.databricks.com/en/sql/user/alerts/index.html) for custom templating instructions. */ customSubject?: pulumi.Input<string>; /** * Name of the alert. */ displayName: pulumi.Input<string>; /** * Whether to notify alert subscribers when alert returns back to normal. */ notifyOnOk?: pulumi.Input<boolean>; /** * Alert owner's username. */ ownerUserName?: pulumi.Input<string>; /** * The path to a workspace folder containing the alert. The default is the user's home folder. If changed, the alert will be recreated. */ parentPath?: pulumi.Input<string>; /** * ID of the query evaluated by the alert. */ queryId: pulumi.Input<string>; /** * Number of seconds an alert must wait after being triggered to rearm itself. After rearming, it can be triggered again. If 0 or not specified, the alert will not be triggered again. */ secondsToRetrigger?: pulumi.Input<number>; }