Class InstrumentSelector

java.lang.Object
io.opentelemetry.sdk.metrics.InstrumentSelector

@Immutable public abstract class InstrumentSelector extends Object
Provides means for selecting one or more instruments. Used for configuring aggregations for the specified instruments.
  • Method Details

    • builder

      public static InstrumentSelectorBuilder builder()
    • getInstrumentType

      @Nullable public abstract InstrumentType getInstrumentType()
      Returns selection criteria for InstrumentType. If null, select instruments with any type.
    • getInstrumentName

      @Nullable public abstract String getInstrumentName()
      Returns the selection criteria for instrument name. If null, select instruments with any name.

      Instrument name may contain the wildcard characters * and ? with the following matching criteria:

      • * matches 0 or more instances of any character
      • ? matches exactly one instance of any character
    • getMeterName

      @Nullable public abstract String getMeterName()
      Returns the selection criteria for meter name. If null, select instruments from meters with any name.
    • getMeterVersion

      @Nullable public abstract String getMeterVersion()
      Returns the selection criteria for meter version. If null, select instruments from meters with any version.
    • getMeterSchemaUrl

      @Nullable public abstract String getMeterSchemaUrl()
      Returns the selection criteria for meter schema url. If null, select instruments from meters with any schema url.