Class Rule

    • Method Detail

      • getAlert

        public String getAlert()
        alert defines the name of the alert. Must be a valid label value. Only one of `record` and `alert` must be set.
      • setAlert

        public void setAlert​(String alert)
        alert defines the name of the alert. Must be a valid label value. Only one of `record` and `alert` must be set.
      • getAnnotations

        public Map<String,​String> getAnnotations()
        annotations defines annotations to add to each alert. Only valid for alerting rules.
      • setAnnotations

        public void setAnnotations​(Map<String,​String> annotations)
        annotations defines annotations to add to each alert. Only valid for alerting rules.
      • getExpr

        public IntOrString getExpr()
        Rule describes an alerting or recording rule See Prometheus documentation: [alerting](https://www.prometheus.io/docs/prometheus/latest/configuration/alerting_rules/) or [recording](https://www.prometheus.io/docs/prometheus/latest/configuration/recording_rules/#recording-rules) rule
      • setExpr

        public void setExpr​(IntOrString expr)
        Rule describes an alerting or recording rule See Prometheus documentation: [alerting](https://www.prometheus.io/docs/prometheus/latest/configuration/alerting_rules/) or [recording](https://www.prometheus.io/docs/prometheus/latest/configuration/recording_rules/#recording-rules) rule
      • getFor

        public String getFor()
        for defines how alerts are considered firing once they have been returned for this long.
      • setFor

        public void setFor​(String _for)
        for defines how alerts are considered firing once they have been returned for this long.
      • getKeepFiringFor

        public String getKeepFiringFor()
        keep_firing_for defines how long an alert will continue firing after the condition that triggered it has cleared.
      • setKeepFiringFor

        public void setKeepFiringFor​(String keepFiringFor)
        keep_firing_for defines how long an alert will continue firing after the condition that triggered it has cleared.
      • getLabels

        public Map<String,​String> getLabels()
        labels defines labels to add or overwrite.
      • setLabels

        public void setLabels​(Map<String,​String> labels)
        labels defines labels to add or overwrite.
      • getRecord

        public String getRecord()
        record defines the name of the time series to output to. Must be a valid metric name. Only one of `record` and `alert` must be set.
      • setRecord

        public void setRecord​(String record)
        record defines the name of the time series to output to. Must be a valid metric name. Only one of `record` and `alert` must be set.
      • getAdditionalProperties

        public Map<String,​Object> getAdditionalProperties()
      • setAdditionalProperty

        public void setAdditionalProperty​(String name,
                                          Object value)
      • setAdditionalProperties

        public void setAdditionalProperties​(Map<String,​Object> additionalProperties)