Class ExporterProperties

java.lang.Object
io.prometheus.metrics.config.ExporterProperties

public class ExporterProperties extends Object
Properties starting with io.prometheus.exporter
  • Field Details

    • INCLUDE_CREATED_TIMESTAMPS

      private static final String INCLUDE_CREATED_TIMESTAMPS
      See Also:
    • PROMETHEUS_TIMESTAMPS_IN_MS

      private static final String PROMETHEUS_TIMESTAMPS_IN_MS
      See Also:
    • EXEMPLARS_ON_ALL_METRIC_TYPES

      private static final String EXEMPLARS_ON_ALL_METRIC_TYPES
      See Also:
    • PREFIX

      private static final String PREFIX
      See Also:
    • includeCreatedTimestamps

      private final Boolean includeCreatedTimestamps
    • prometheusTimestampsInMs

      private final Boolean prometheusTimestampsInMs
    • exemplarsOnAllMetricTypes

      private final Boolean exemplarsOnAllMetricTypes
  • Constructor Details

    • ExporterProperties

      private ExporterProperties(Boolean includeCreatedTimestamps, Boolean prometheusTimestampsInMs, Boolean exemplarsOnAllMetricTypes)
  • Method Details

    • getIncludeCreatedTimestamps

      public boolean getIncludeCreatedTimestamps()
      Include the _created timestamps in text format? Default is false.
    • getPrometheusTimestampsInMs

      public boolean getPrometheusTimestampsInMs()
      Use milliseconds for timestamps in prometheus text format? Default is false.
    • getExemplarsOnAllMetricTypes

      public boolean getExemplarsOnAllMetricTypes()
      Allow Exemplars on all metric types in OpenMetrics format? Default is false, which means Exemplars will only be added for Counters and Histogram buckets.
    • load

      Note that this will remove entries from propertySource. This is because we want to know if there are unused properties remaining after all properties have been loaded.
      Throws:
      PrometheusPropertiesException
    • builder

      public static ExporterProperties.Builder builder()