Class ServiceLevelAgreementBoundary
- java.lang.Object
-
- io.micrometer.spring.autoconfigure.ServiceLevelAgreementBoundary
-
public final class ServiceLevelAgreementBoundary extends java.lang.ObjectA service level agreement boundary for use when configuring Micrometer. Can be specified as either aLong(applicable to timers and distribution summaries) or aDuration(applicable to only timers).
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.LonggetValue(io.micrometer.core.instrument.Meter.Type meterType)Return the underlying value of the SLA in form suitable to apply to the given meter type.static ServiceLevelAgreementBoundaryvalueOf(long value)Return a newServiceLevelAgreementBoundaryinstance for the given long value.static ServiceLevelAgreementBoundaryvalueOf(java.lang.String value)Return a newServiceLevelAgreementBoundaryinstance for the given long value.
-
-
-
Method Detail
-
getValue
public java.lang.Long getValue(io.micrometer.core.instrument.Meter.Type meterType)
Return the underlying value of the SLA in form suitable to apply to the given meter type.- Parameters:
meterType- the meter type- Returns:
- the value or
nullif the value cannot be applied
-
valueOf
public static ServiceLevelAgreementBoundary valueOf(long value)
Return a newServiceLevelAgreementBoundaryinstance for the given long value.- Parameters:
value- the source value- Returns:
- a
ServiceLevelAgreementBoundaryinstance
-
valueOf
public static ServiceLevelAgreementBoundary valueOf(java.lang.String value)
Return a newServiceLevelAgreementBoundaryinstance for the given long value.- Parameters:
value- the source value- Returns:
- a
ServiceLevelAgreementBoundaryinstance
-
-