Package io.micrometer.core.instrument
Interface Meter.MeterProvider<T extends Meter>
- Type Parameters:
T
- Meter type
- Enclosing interface:
Meter
public static interface Meter.MeterProvider<T extends Meter>
Convenience interface to create new meters from tags based on a common
"template"/builder. See usage in Meter implementations, e.g.:
Timer
,
Counter
- Since:
- 1.12.0
-
Method Summary
Modifier and TypeMethodDescriptiondefault T
Registers (creates a new or gets an existing one if already exists) Meters using the provided tags.Registers (creates a new or gets an existing one if already exists) Meters using the provided tags.default T
Registers (creates a new or gets an existing one if already exists) Meters using the provided tags.
-
Method Details
-
withTags
Registers (creates a new or gets an existing one if already exists) Meters using the provided tags.- Parameters:
tags
- Tags to attach to the Meter about to be registered- Returns:
- A new or existing Meter
-
withTags
Registers (creates a new or gets an existing one if already exists) Meters using the provided tags.- Parameters:
tags
- Tags to attach to the Meter about to be registered- Returns:
- A new or existing Meter
-
withTag
Registers (creates a new or gets an existing one if already exists) Meters using the provided tags.- Parameters:
key
- the tag key to addvalue
- the tag value to add- Returns:
- A new or existing Meter
-