Detector
Provides a SignalFx detector resource. This can be used to create and manage detectors. As SignalFx supports different notification mechanisms a comma-delimited string is used to provide inputs. If you’d like to specify multiple notifications, then each should be a member in the list.
NOTE If you’re interested in using SignalFx detector features such as Historical Anomaly, Resource Running Out, or others then consider building them in the UI first then using the “Show SignalFlow” feature to extract the value for
program_text. You may also consult the documentation for detector functions in signalflow-library.
Create a Detector Resource
new Detector(name: string, args: DetectorArgs, opts?: CustomResourceOptions);def Detector(resource_name, opts=None, authorized_writer_teams=None, authorized_writer_users=None, description=None, disable_sampling=None, end_time=None, max_delay=None, name=None, program_text=None, rules=None, show_data_markers=None, show_event_lines=None, start_time=None, teams=None, time_range=None, viz_options=None, __props__=None);func NewDetector(ctx *Context, name string, args DetectorArgs, opts ...ResourceOption) (*Detector, error)public Detector(string name, DetectorArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args DetectorArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args DetectorArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args DetectorArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
Detector Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The Detector resource accepts the following input properties:
- Program
Text string Signalflow program text for the detector. More info in the SignalFx docs.
- Rules
List<Pulumi.
Signal Fx. Inputs. Detector Rule Args> Set of rules used for alerting.
- List<string>
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- List<string>
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- Description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- Disable
Sampling bool When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- End
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Max
Delay int How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- Name string
Name of the detector.
- Show
Data boolMarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- Show
Event boolLines When
true, the visualization will display a vertical line for each event trigger.falseby default.- Start
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Teams List<string>
Team IDs to associate the detector to.
- Time
Range int Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- Viz
Options List<Pulumi.Signal Fx. Inputs. Detector Viz Option Args> Plot-level customization options, associated with a publish statement.
- Program
Text string Signalflow program text for the detector. More info in the SignalFx docs.
- Rules
[]Detector
Rule Set of rules used for alerting.
- []string
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- []string
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- Description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- Disable
Sampling bool When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- End
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Max
Delay int How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- Name string
Name of the detector.
- Show
Data boolMarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- Show
Event boolLines When
true, the visualization will display a vertical line for each event trigger.falseby default.- Start
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Teams []string
Team IDs to associate the detector to.
- Time
Range int Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- Viz
Options []DetectorViz Option Plot-level customization options, associated with a publish statement.
- program
Text string Signalflow program text for the detector. More info in the SignalFx docs.
- rules
Detector
Rule[] Set of rules used for alerting.
- string[]
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- string[]
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- disable
Sampling boolean When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- end
Time number Seconds since epoch. Used for visualization. Conflicts with
time_range.- max
Delay number How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- name string
Name of the detector.
- show
Data booleanMarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- show
Event booleanLines When
true, the visualization will display a vertical line for each event trigger.falseby default.- start
Time number Seconds since epoch. Used for visualization. Conflicts with
time_range.- teams string[]
Team IDs to associate the detector to.
- time
Range number Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- viz
Options DetectorViz Option[] Plot-level customization options, associated with a publish statement.
- program_
text str Signalflow program text for the detector. More info in the SignalFx docs.
- rules
List[Detector
Rule] Set of rules used for alerting.
- List[str]
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- List[str]
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- description str
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- disable_
sampling bool When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- end_
time float Seconds since epoch. Used for visualization. Conflicts with
time_range.- max_
delay float How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- name str
Name of the detector.
- show_
data_ boolmarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- show_
event_ boollines When
true, the visualization will display a vertical line for each event trigger.falseby default.- start_
time float Seconds since epoch. Used for visualization. Conflicts with
time_range.- teams List[str]
Team IDs to associate the detector to.
- time_
range float Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- viz_
options List[DetectorViz Option] Plot-level customization options, associated with a publish statement.
Outputs
All input properties are implicitly available as output properties. Additionally, the Detector resource produces the following output properties:
Look up an Existing Detector Resource
Get an existing Detector resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: DetectorState, opts?: CustomResourceOptions): Detectorstatic get(resource_name, id, opts=None, authorized_writer_teams=None, authorized_writer_users=None, description=None, disable_sampling=None, end_time=None, max_delay=None, name=None, program_text=None, rules=None, show_data_markers=None, show_event_lines=None, start_time=None, teams=None, time_range=None, url=None, viz_options=None, __props__=None);func GetDetector(ctx *Context, name string, id IDInput, state *DetectorState, opts ...ResourceOption) (*Detector, error)public static Detector Get(string name, Input<string> id, DetectorState? state, CustomResourceOptions? opts = null)- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
The following state arguments are supported:
- List<string>
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- List<string>
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- Description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- Disable
Sampling bool When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- End
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Max
Delay int How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- Name string
Name of the detector.
- Program
Text string Signalflow program text for the detector. More info in the SignalFx docs.
- Rules
List<Pulumi.
Signal Fx. Inputs. Detector Rule Args> Set of rules used for alerting.
- Show
Data boolMarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- Show
Event boolLines When
true, the visualization will display a vertical line for each event trigger.falseby default.- Start
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Teams List<string>
Team IDs to associate the detector to.
- Time
Range int Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- Url string
URL of the detector
- Viz
Options List<Pulumi.Signal Fx. Inputs. Detector Viz Option Args> Plot-level customization options, associated with a publish statement.
- []string
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- []string
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- Description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- Disable
Sampling bool When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- End
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Max
Delay int How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- Name string
Name of the detector.
- Program
Text string Signalflow program text for the detector. More info in the SignalFx docs.
- Rules
[]Detector
Rule Set of rules used for alerting.
- Show
Data boolMarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- Show
Event boolLines When
true, the visualization will display a vertical line for each event trigger.falseby default.- Start
Time int Seconds since epoch. Used for visualization. Conflicts with
time_range.- Teams []string
Team IDs to associate the detector to.
- Time
Range int Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- Url string
URL of the detector
- Viz
Options []DetectorViz Option Plot-level customization options, associated with a publish statement.
- string[]
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- string[]
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- disable
Sampling boolean When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- end
Time number Seconds since epoch. Used for visualization. Conflicts with
time_range.- max
Delay number How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- name string
Name of the detector.
- program
Text string Signalflow program text for the detector. More info in the SignalFx docs.
- rules
Detector
Rule[] Set of rules used for alerting.
- show
Data booleanMarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- show
Event booleanLines When
true, the visualization will display a vertical line for each event trigger.falseby default.- start
Time number Seconds since epoch. Used for visualization. Conflicts with
time_range.- teams string[]
Team IDs to associate the detector to.
- time
Range number Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- url string
URL of the detector
- viz
Options DetectorViz Option[] Plot-level customization options, associated with a publish statement.
- List[str]
Team IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s team id (or user id in
authorized_writer_users).- List[str]
User IDs that have write access to this detector. Remember to use an admin’s token if using this feature and to include that admin’s user id (or team id in
authorized_writer_teams).- description str
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- disable_
sampling bool When
false, the visualization may sample the output timeseries rather than displaying them all.falseby default.- end_
time float Seconds since epoch. Used for visualization. Conflicts with
time_range.- max_
delay float How long (in seconds) to wait for late datapoints. See Delayed Datapoints for more info. Max value is
900seconds (15 minutes).Auto(as little as possible) by default.- name str
Name of the detector.
- program_
text str Signalflow program text for the detector. More info in the SignalFx docs.
- rules
List[Detector
Rule] Set of rules used for alerting.
- show_
data_ boolmarkers When
true, markers will be drawn for each datapoint within the visualization.trueby default.- show_
event_ boollines When
true, the visualization will display a vertical line for each event trigger.falseby default.- start_
time float Seconds since epoch. Used for visualization. Conflicts with
time_range.- teams List[str]
Team IDs to associate the detector to.
- time_
range float Seconds to display in the visualization. This is a rolling range from the current time. Example:
3600corresponds to-1hin web UI.3600by default.- url str
URL of the detector
- viz_
options List[DetectorViz Option] Plot-level customization options, associated with a publish statement.
Supporting Types
DetectorRule
- Detect
Label string A detect label which matches a detect label within
program_text.- Severity string
The severity of the rule, must be one of:
"Critical","Major","Minor","Warning","Info".- Description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- Disabled bool
When true, notifications and events will not be generated for the detect label.
falseby default.- Notifications List<string>
List of strings specifying where notifications will be sent when an incident occurs. See Create A Single Detector for more info.
- Parameterized
Body string Custom notification message body when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- Parameterized
Subject string Custom notification message subject when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- Runbook
Url string URL of page to consult when an alert is triggered. This can be used with custom notification messages.
- Tip string
Plain text suggested first course of action, such as a command line to execute. This can be used with custom notification messages.
- Detect
Label string A detect label which matches a detect label within
program_text.- Severity string
The severity of the rule, must be one of:
"Critical","Major","Minor","Warning","Info".- Description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- Disabled bool
When true, notifications and events will not be generated for the detect label.
falseby default.- Notifications []string
List of strings specifying where notifications will be sent when an incident occurs. See Create A Single Detector for more info.
- Parameterized
Body string Custom notification message body when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- Parameterized
Subject string Custom notification message subject when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- Runbook
Url string URL of page to consult when an alert is triggered. This can be used with custom notification messages.
- Tip string
Plain text suggested first course of action, such as a command line to execute. This can be used with custom notification messages.
- detect
Label string A detect label which matches a detect label within
program_text.- severity string
The severity of the rule, must be one of:
"Critical","Major","Minor","Warning","Info".- description string
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- disabled boolean
When true, notifications and events will not be generated for the detect label.
falseby default.- notifications string[]
List of strings specifying where notifications will be sent when an incident occurs. See Create A Single Detector for more info.
- parameterized
Body string Custom notification message body when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- parameterized
Subject string Custom notification message subject when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- runbook
Url string URL of page to consult when an alert is triggered. This can be used with custom notification messages.
- tip string
Plain text suggested first course of action, such as a command line to execute. This can be used with custom notification messages.
- detect
Label str A detect label which matches a detect label within
program_text.- severity str
The severity of the rule, must be one of:
"Critical","Major","Minor","Warning","Info".- description str
Description for the rule. Displays as the alert condition in the Alert Rules tab of the detector editor in the web UI.
- disabled bool
When true, notifications and events will not be generated for the detect label.
falseby default.- notifications List[str]
List of strings specifying where notifications will be sent when an incident occurs. See Create A Single Detector for more info.
- parameterized
Body str Custom notification message body when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- parameterized
Subject str Custom notification message subject when an alert is triggered. See Set Up Detectors to Trigger Alerts for more info.
- runbook
Url str URL of page to consult when an alert is triggered. This can be used with custom notification messages.
- tip str
Plain text suggested first course of action, such as a command line to execute. This can be used with custom notification messages.
DetectorVizOption
- Label string
Label used in the publish statement that displays the plot (metric time series data) you want to customize.
- Color string
Color to use : gray, blue, azure, navy, brown, orange, yellow, iris, magenta, pink, purple, violet, lilac, emerald, green, aquamarine.
- Display
Name string Specifies an alternate value for the Plot Name column of the Data Table associated with the chart.
- Value
Prefix string - Value
Suffix string - Value
Unit string A unit to attach to this plot. Units support automatic scaling (eg thousands of bytes will be displayed as kilobytes). Values values are
Bit, Kilobit, Megabit, Gigabit, Terabit, Petabit, Exabit, Zettabit, Yottabit, Byte, Kibibyte, Mebibyte, Gigibyte, Tebibyte, Pebibyte, Exbibyte, Zebibyte, Yobibyte, Nanosecond, Microsecond, Millisecond, Second, Minute, Hour, Day, Week. *value_prefix,value_suffix- (Optional) Arbitrary prefix/suffix to display with the value of this plot.
- Label string
Label used in the publish statement that displays the plot (metric time series data) you want to customize.
- Color string
Color to use : gray, blue, azure, navy, brown, orange, yellow, iris, magenta, pink, purple, violet, lilac, emerald, green, aquamarine.
- Display
Name string Specifies an alternate value for the Plot Name column of the Data Table associated with the chart.
- Value
Prefix string - Value
Suffix string - Value
Unit string A unit to attach to this plot. Units support automatic scaling (eg thousands of bytes will be displayed as kilobytes). Values values are
Bit, Kilobit, Megabit, Gigabit, Terabit, Petabit, Exabit, Zettabit, Yottabit, Byte, Kibibyte, Mebibyte, Gigibyte, Tebibyte, Pebibyte, Exbibyte, Zebibyte, Yobibyte, Nanosecond, Microsecond, Millisecond, Second, Minute, Hour, Day, Week. *value_prefix,value_suffix- (Optional) Arbitrary prefix/suffix to display with the value of this plot.
- label string
Label used in the publish statement that displays the plot (metric time series data) you want to customize.
- color string
Color to use : gray, blue, azure, navy, brown, orange, yellow, iris, magenta, pink, purple, violet, lilac, emerald, green, aquamarine.
- display
Name string Specifies an alternate value for the Plot Name column of the Data Table associated with the chart.
- value
Prefix string - value
Suffix string - value
Unit string A unit to attach to this plot. Units support automatic scaling (eg thousands of bytes will be displayed as kilobytes). Values values are
Bit, Kilobit, Megabit, Gigabit, Terabit, Petabit, Exabit, Zettabit, Yottabit, Byte, Kibibyte, Mebibyte, Gigibyte, Tebibyte, Pebibyte, Exbibyte, Zebibyte, Yobibyte, Nanosecond, Microsecond, Millisecond, Second, Minute, Hour, Day, Week. *value_prefix,value_suffix- (Optional) Arbitrary prefix/suffix to display with the value of this plot.
- label str
Label used in the publish statement that displays the plot (metric time series data) you want to customize.
- color str
Color to use : gray, blue, azure, navy, brown, orange, yellow, iris, magenta, pink, purple, violet, lilac, emerald, green, aquamarine.
- display
Name str Specifies an alternate value for the Plot Name column of the Data Table associated with the chart.
- value
Prefix str - value
Suffix str - value
Unit str A unit to attach to this plot. Units support automatic scaling (eg thousands of bytes will be displayed as kilobytes). Values values are
Bit, Kilobit, Megabit, Gigabit, Terabit, Petabit, Exabit, Zettabit, Yottabit, Byte, Kibibyte, Mebibyte, Gigibyte, Tebibyte, Pebibyte, Exbibyte, Zebibyte, Yobibyte, Nanosecond, Microsecond, Millisecond, Second, Minute, Hour, Day, Week. *value_prefix,value_suffix- (Optional) Arbitrary prefix/suffix to display with the value of this plot.
Package Details
- Repository
- https://github.com/pulumi/pulumi-signalfx
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
signalfxTerraform Provider.