Package io.opentelemetry.api.metrics
Interface MeterProvider
-
- All Known Implementing Classes:
DefaultMeterProvider
,ExtendedDefaultMeterProvider
,OpenTelemetrySdk.ObfuscatedMeterProvider
,SdkMeterProvider
@ThreadSafe public interface MeterProvider
A registry for creating namedMeter
s.The name Provider is for consistency with other languages and it is NOT loaded using reflection.
- Since:
- 1.10.0
- See Also:
Meter
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default Meter
get(java.lang.String instrumentationScopeName)
Gets or creates a named Meter instance.MeterBuilder
meterBuilder(java.lang.String instrumentationScopeName)
Creates a MeterBuilder for a named Meter instance.static MeterProvider
noop()
Returns a no-opMeterProvider
which provides meters which do not record or emit.
-
-
-
Method Detail
-
get
default Meter get(java.lang.String instrumentationScopeName)
Gets or creates a named Meter instance.- Parameters:
instrumentationScopeName
- A name uniquely identifying the instrumentation scope, such as the instrumentation library, package, or fully qualified class name. Must not be null.- Returns:
- a Meter instance.
-
meterBuilder
MeterBuilder meterBuilder(java.lang.String instrumentationScopeName)
Creates a MeterBuilder for a named Meter instance.- Parameters:
instrumentationScopeName
- A name uniquely identifying the instrumentation scope, such as the instrumentation library, package, or fully qualified class name. Must not be null.- Returns:
- a MeterBuilder instance.
-
noop
static MeterProvider noop()
Returns a no-opMeterProvider
which provides meters which do not record or emit.
-
-