Class ScrapeClass

  • All Implemented Interfaces:
    io.fabric8.kubernetes.api.builder.Editable<ScrapeClassBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource, Serializable

    @Generated("io.fabric8.kubernetes.schema.generator.model.ModelGenerator")
    public class ScrapeClass
    extends Object
    implements io.fabric8.kubernetes.api.builder.Editable<ScrapeClassBuilder>, io.fabric8.kubernetes.api.model.KubernetesResource
    See Also:
    Serialized Form
    • Method Detail

      • setAttachMetadata

        public void setAttachMetadata​(AttachMetadata attachMetadata)
      • setAuthorization

        public void setAuthorization​(Authorization authorization)
      • getDefault

        public Boolean getDefault()
        Default indicates that the scrape applies to all scrape objects that don't configure an explicit scrape class name.


        Only one scrape class can be set as the default.

      • setDefault

        public void setDefault​(Boolean _default)
        Default indicates that the scrape applies to all scrape objects that don't configure an explicit scrape class name.


        Only one scrape class can be set as the default.

      • getFallbackScrapeProtocol

        public String getFallbackScrapeProtocol()
        The protocol to use if a scrape returns blank, unparseable, or otherwise invalid Content-Type. It will only apply if the scrape resource doesn't specify any FallbackScrapeProtocol


        It requires Prometheus >= v3.0.0.

      • setFallbackScrapeProtocol

        public void setFallbackScrapeProtocol​(String fallbackScrapeProtocol)
        The protocol to use if a scrape returns blank, unparseable, or otherwise invalid Content-Type. It will only apply if the scrape resource doesn't specify any FallbackScrapeProtocol


        It requires Prometheus >= v3.0.0.

      • getMetricRelabelings

        public List<RelabelConfig> getMetricRelabelings()
        MetricRelabelings configures the relabeling rules to apply to all samples before ingestion.


        The Operator adds the scrape class metric relabelings defined here. Then the Operator adds the target-specific metric relabelings defined in ServiceMonitors, PodMonitors, Probes and ScrapeConfigs. Then the Operator adds namespace enforcement relabeling rule, specified in '.spec.enforcedNamespaceLabel'.


        More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#metric_relabel_configs

      • setMetricRelabelings

        public void setMetricRelabelings​(List<RelabelConfig> metricRelabelings)
        MetricRelabelings configures the relabeling rules to apply to all samples before ingestion.


        The Operator adds the scrape class metric relabelings defined here. Then the Operator adds the target-specific metric relabelings defined in ServiceMonitors, PodMonitors, Probes and ScrapeConfigs. Then the Operator adds namespace enforcement relabeling rule, specified in '.spec.enforcedNamespaceLabel'.


        More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#metric_relabel_configs

      • getName

        public String getName()
        Name of the scrape class.
      • setName

        public void setName​(String name)
        Name of the scrape class.
      • getRelabelings

        public List<RelabelConfig> getRelabelings()
        Relabelings configures the relabeling rules to apply to all scrape targets.


        The Operator automatically adds relabelings for a few standard Kubernetes fields like `__meta_kubernetes_namespace` and `__meta_kubernetes_service_name`. Then the Operator adds the scrape class relabelings defined here. Then the Operator adds the target-specific relabelings defined in the scrape object.


        More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config

      • setRelabelings

        public void setRelabelings​(List<RelabelConfig> relabelings)
        Relabelings configures the relabeling rules to apply to all scrape targets.


        The Operator automatically adds relabelings for a few standard Kubernetes fields like `__meta_kubernetes_namespace` and `__meta_kubernetes_service_name`. Then the Operator adds the scrape class relabelings defined here. Then the Operator adds the target-specific relabelings defined in the scrape object.


        More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config

      • getTlsConfig

        public TLSConfig getTlsConfig()
      • setTlsConfig

        public void setTlsConfig​(TLSConfig tlsConfig)
      • getAdditionalProperties

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

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

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