Skip to content

Variables

Quentin Manfroi edited this page Feb 17, 2022 · 20 revisions

🔗 Contents

Every variables have different properties:

  • required: not to be confused with the terraform notion which make any variable without default value required. Here it means required to declare in the detectors templating. These variables could be dormant (empty value) but are declared as terraform variable in the module and this variable is used in the terraform resources.
  • scopes: a variable must have, at least, one scope. In case of multiple scopes are supported so there exist different variable for each scope which could override the scope of its "higher version" variable. It could be global, per detector (prefix name with [id]_) or per rule per detector (prefix name with [id]_ and suffix it with _[severity].
  • type which refer to terraform type constraints
  • description: a short summary of what it does

environment

description: Infrastructure environment

type: string

required: true

scopes: global

notifications

description: Default notification recipients list per severity

type: object({ critical=list(string) major=list(string) minor=list(string) warning=list(string) info=list(string) })

required: true

scopes: global, detector

prefixes

description: Prefixes list to prepend between brackets on every monitors names before environment

type: list

required: true

scopes: global

filtering_custom

description: Filters as SignalFlow string to either replace or append to default filtering convention which is the only one used if not defined

type: string

required: true

scopes: global

filtering_append

description: If true, the filtering_custom string will be appended to the default filtering convention instead of fully replace it

type: bool

required: true

scopes: global

disabled

description:"Disable alerting rules. The global variable allowing to disabling all detectors of a module is detectors_disabled."

type: bool

required: true

scopes: global, detector, rule

aggregation_function

description: Aggregation function and group by for [id] detector (i.e. .mean(by=['host']))

type: string

required: true

scopes: detector

transformation_function

description: Transformation function for [id] detector (i.e. .mean(over='5m'))"

type: string

required: true

scopes: detector

threshold

description: [severity] threshold for [id] detector"

type: number

required: true

scopes: rule

lasting_duration_seconds DEPRECATED

description: Use lasting_duration instead which allow define time unit and is per rule scope only

type: number

required: false

scopes: detector

lasting_duration

description: Minimum duration that conditions must be true before raising alert

type: string

required: true

scopes: rule

at_least_percentage

description: Percentage of lasting that conditions must be true before raising alert (>= 0.0 and <= 1.0)

type: number

required: true

scopes: rule (DEPRECATED: detector)

runbook_url

description: URL like SignalFx dashboard or wiki page which can help to troubleshoot the incident cause

type: string

required: true

scopes: global, detector

tip

description: Suggested first course of action or any note useful for incident handling

type: string

required: true

scopes: detector

authorized_writer_teams

description: List of teams IDs authorized to edit the detector. All admins are able to edit and must not be added to this. Be careful, if a list is defined so a long lived org token will not work anymore to apply. It will require a short lived user token from an authorized user (or an admin).

type: list(string)

required: true

scopes: global

teams

description: List of teams IDs to associate the detector to. Be careful, you can also want to add this team as notification recipient also

type: list(string)

required: true

scopes: global

message_body

description: Allows the user to define his own body message template to any value. By default set to "" empty string it will use our internal template. Set it to null to use the default template from SignalFx (it works only if subject is also set to null).

type: string

required: true

scopes: global

message_subject

description: Allows the user to define his own subject message template to any value. By default set to "" empty string it will use our internal template. Set it to null to use the default template from SignalFx (it works only if body is also set to null).

type: string

required: true

scopes: global

extra_tags

description: List of tags to append to the default ones automatically added from module for context purpose. For now, they are only usable from the API to find and filter detectors

type: list(string)

required: true

scopes: global

max_delay

description: Allows the user to enforce a specific max delay for the detector. See the official documentation for more information about delayed datapoints. It can be set to either 0 or null to let SignalFx determine the minimum value dynamically. By default, it is null except for heartbeat based detectors where 900 is used to force evaluation to wait for any required properties.

type: number

required: false

scopes: detector