Class AlertCondition
Use this resource to create and manage plugins alert conditions in New Relic.
Terms
The term mapping supports the following arguments:
duration- (Required) In minutes, must be in the range of5to120, inclusive.operator- (Optional)above,below, orequal. Defaults toequal.priority- (Optional)criticalorwarning. Defaults tocritical.threshold- (Required) Must be 0 or greater.time_function- (Required)allorany.
Inherited Members
Namespace: Pulumi.NewRelic.Plugins
Assembly: Pulumi.NewRelic.dll
Syntax
public class AlertCondition : CustomResource
Constructors
View SourceAlertCondition(String, AlertConditionArgs, CustomResourceOptions)
Create a AlertCondition resource with the given unique name, arguments, and options.
Declaration
public AlertCondition(string name, AlertConditionArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| AlertConditionArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceEnabled
Whether or not this condition is enabled.
Declaration
public Output<bool?> Enabled { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Nullable<System.Boolean>> |
Entities
The plugin component IDs to target.
Declaration
public Output<ImmutableArray<int>> Entities { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableArray<System.Int32>> |
Metric
The plugin metric to evaluate.
Declaration
public Output<string> Metric { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
MetricDescription
The metric description.
Declaration
public Output<string> MetricDescription { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Name
The title of the condition. Must be between 1 and 64 characters, inclusive.
Declaration
public Output<string> Name { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
PluginGuid
The GUID of the plugin which produces the metric.
Declaration
public Output<string> PluginGuid { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
PluginId
The ID of the installed plugin instance which produces the metric.
Declaration
public Output<string> PluginId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
PolicyId
The ID of the policy where this condition should be used.
Declaration
public Output<int> PolicyId { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Int32> |
RunbookUrl
Runbook URL to display in notifications.
Declaration
public Output<string> RunbookUrl { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Terms
A list of terms for this condition. See Terms below for details.
Declaration
public Output<ImmutableArray<AlertConditionTerm>> Terms { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.Collections.Immutable.ImmutableArray<AlertConditionTerm>> |
ValueFunction
The value function to apply to the metric data. One of min, max, average, sample_size, total, or percent.
Declaration
public Output<string> ValueFunction { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, AlertConditionState, CustomResourceOptions)
Get an existing AlertCondition resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static AlertCondition Get(string name, Input<string> id, AlertConditionState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| AlertConditionState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| AlertCondition |