Class InstrumentedAppender
java.lang.Object
ch.qos.logback.core.spi.ContextAwareBase
ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>
io.prometheus.client.logback.InstrumentedAppender
- All Implemented Interfaces:
ch.qos.logback.core.Appender<ch.qos.logback.classic.spi.ILoggingEvent>, ch.qos.logback.core.spi.ContextAware, ch.qos.logback.core.spi.FilterAttachable<ch.qos.logback.classic.spi.ILoggingEvent>, ch.qos.logback.core.spi.LifeCycle
public class InstrumentedAppender
extends ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringprivate final Counter.Childprivate static final Counterprivate final Counter.Childprivate final Counter.Childprivate final Counter.Childprivate final Counter.ChildFields inherited from class ch.qos.logback.core.UnsynchronizedAppenderBase
name, startedFields inherited from class ch.qos.logback.core.spi.ContextAwareBase
context -
Constructor Summary
ConstructorsModifierConstructorDescriptionCreate a new instrumented appender using the default registry.InstrumentedAppender(CollectorRegistry registry) Create a new instrumented appender using the supplied registry.privateInstrumentedAppender(Counter counter) -
Method Summary
Methods inherited from class ch.qos.logback.core.UnsynchronizedAppenderBase
addFilter, clearAllFilters, doAppend, getCopyOfAttachedFiltersList, getFilterChainDecision, getName, isStarted, setName, stop, toStringMethods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContextMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface ch.qos.logback.core.spi.ContextAware
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, setContext
-
Field Details
-
COUNTER_NAME
- See Also:
-
defaultCounter
-
traceCounter
-
debugCounter
-
infoCounter
-
warnCounter
-
errorCounter
-
-
Constructor Details
-
InstrumentedAppender
public InstrumentedAppender()Create a new instrumented appender using the default registry. -
InstrumentedAppender
Create a new instrumented appender using the supplied registry. -
InstrumentedAppender
-
-
Method Details
-
start
public void start()- Specified by:
startin interfacech.qos.logback.core.spi.LifeCycle- Overrides:
startin classch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>
-
append
protected void append(ch.qos.logback.classic.spi.ILoggingEvent event) - Specified by:
appendin classch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>
-