Class OnlyOnceLoggingDenyMeterFilter
java.lang.Object
org.springframework.boot.actuate.autoconfigure.metrics.OnlyOnceLoggingDenyMeterFilter
- All Implemented Interfaces:
io.micrometer.core.instrument.config.MeterFilter
public final class OnlyOnceLoggingDenyMeterFilter
extends Object
implements io.micrometer.core.instrument.config.MeterFilter
MeterFilter to log a single warning message and deny a Meter.Id
after a number of attempts for a given tag.- Since:
- 2.0.5
-
Constructor Summary
ConstructorsConstructorDescriptionOnlyOnceLoggingDenyMeterFilter(String meterNamePrefix, String tagKey, int maximumTagValues) Create a newOnlyOnceLoggingDenyMeterFilterwith an upper bound on the number of tags produced by matching metrics.OnlyOnceLoggingDenyMeterFilter(String meterNamePrefix, String tagKey, int maximumTagValues, String hint) Create a newOnlyOnceLoggingDenyMeterFilterwith an upper bound on the number of tags produced by matching metrics.OnlyOnceLoggingDenyMeterFilter(Supplier<String> message) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionio.micrometer.core.instrument.config.MeterFilterReplyaccept(io.micrometer.core.instrument.Meter.Id id) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.micrometer.core.instrument.config.MeterFilter
configure, map
-
Constructor Details
-
OnlyOnceLoggingDenyMeterFilter
@Deprecated(since="3.4.12", forRemoval=true) public OnlyOnceLoggingDenyMeterFilter(Supplier<String> message) Deprecated, for removal: This API element is subject to removal in a future version.since 3.4.12 in favor ofOnlyOnceLoggingDenyMeterFilter(String, String, int, String)Create a newOnlyOnceLoggingDenyMeterFilterinstance.- Parameters:
message- the message to log- Since:
- 2.0.5
-
OnlyOnceLoggingDenyMeterFilter
Create a newOnlyOnceLoggingDenyMeterFilterwith an upper bound on the number of tags produced by matching metrics.- Parameters:
meterNamePrefix- the prefix of the meter name to apply the filter totagKey- the tag to place an upper bound onmaximumTagValues- the total number of tag values that are allowable- Since:
- 3.4.12
-
OnlyOnceLoggingDenyMeterFilter
public OnlyOnceLoggingDenyMeterFilter(String meterNamePrefix, String tagKey, int maximumTagValues, String hint) Create a newOnlyOnceLoggingDenyMeterFilterwith an upper bound on the number of tags produced by matching metrics.- Parameters:
meterNamePrefix- the prefix of the meter name to apply the filter totagKey- the tag to place an upper bound onmaximumTagValues- the total number of tag values that are allowablehint- an additional hint to add to the logged message ornull- Since:
- 3.4.12
-
-
Method Details
-
accept
public io.micrometer.core.instrument.config.MeterFilterReply accept(io.micrometer.core.instrument.Meter.Id id) - Specified by:
acceptin interfaceio.micrometer.core.instrument.config.MeterFilter
-
OnlyOnceLoggingDenyMeterFilter(String, String, int, String)