Class QuarkusDelayedHandler
- All Implemented Interfaces:
Flushable,AutoCloseable
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThis is a system property that can be used to help debug startup issues if TRACE and DEBUG logs are being dropped due to the queue limit being exceeded.Fields inherited from class org.jboss.logmanager.ExtHandler
handlers, handlersUpdater, lock -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddHandler(Handler handler) voidaddLoggingCloseTask(Runnable runnable) voidHandler[]final voidclose()protected voiddoPublish(org.jboss.logmanager.ExtLogRecord record) final booleanIndicates whether or not this handler has been activated.booleanvoidremoveHandler(Handler handler) Handler[]setBuildTimeHandlers(Handler[] newHandlers) voidsetCallerCalculationRequired(boolean callerCalculationRequired) Sets whether or not caller information will be required when formatting records.Handler[]setHandlers(Handler[] newHandlers) Methods inherited from class org.jboss.logmanager.ExtHandler
checkAccess, checkAccess, flush, getCharset, getEncoding, getErrorManager, getFilter, getFormatter, getHandlers, getLevel, isAutoFlush, isCloseChildren, isEnabled, publish, publish, publishToNestedHandlers, reportError, reportError, setAutoFlush, setCharset, setCharsetPrivate, setCloseChildren, setEnabled, setEncoding, setErrorManager, setFilter, setFormatter, setLevelMethods inherited from class java.util.logging.Handler
isLoggable
-
Field Details
-
QUARKUS_LOG_MAX_STARTUP_RECORDS
This is a system property that can be used to help debug startup issues if TRACE and DEBUG logs are being dropped due to the queue limit being exceeded. This is not a normal config property, and is unlikely to be needed under normal usage.- See Also:
-
-
Constructor Details
-
QuarkusDelayedHandler
public QuarkusDelayedHandler() -
QuarkusDelayedHandler
public QuarkusDelayedHandler(int queueLimit)
-
-
Method Details
-
doPublish
protected void doPublish(org.jboss.logmanager.ExtLogRecord record) - Overrides:
doPublishin classorg.jboss.logmanager.ExtHandler
-
close
- Specified by:
closein interfaceAutoCloseable- Overrides:
closein classorg.jboss.logmanager.ExtHandler- Throws:
SecurityException
-
addHandler
Note that once this is invoked the handler will be activated and the messages will no longer be queued. If more than one child handler is required the
setHandlers(Handler[])should be used.- Overrides:
addHandlerin classorg.jboss.logmanager.ExtHandler- Throws:
SecurityException- See Also:
-
setHandlers
Note that once this is invoked the handler will be activated and the messages will no longer be queued.
- Overrides:
setHandlersin classorg.jboss.logmanager.ExtHandler- Throws:
SecurityException
-
addLoggingCloseTask
-
setBuildTimeHandlers
- Throws:
SecurityException
-
buildTimeComplete
public void buildTimeComplete() -
removeHandler
Note that if the last child handler is removed the handler will no longer be activated and the messages will again be queued.
- Overrides:
removeHandlerin classorg.jboss.logmanager.ExtHandler- Throws:
SecurityException- See Also:
-
clearHandlers
Note that once this is invoked the handler will no longer be activated and messages will again be queued.
- Overrides:
clearHandlersin classorg.jboss.logmanager.ExtHandler- Throws:
SecurityException- See Also:
-
isCallerCalculationRequired
public boolean isCallerCalculationRequired()This can be overridden to always require the caller calculation by setting the
setCallerCalculationRequired(boolean)value totrue.- Overrides:
isCallerCalculationRequiredin classorg.jboss.logmanager.ExtHandler- See Also:
-
setCallerCalculationRequired
public void setCallerCalculationRequired(boolean callerCalculationRequired) Sets whether or not caller information will be required when formatting records.If set to
truethe caller information will be calculated for each record that is placed in the queue. A value offalsemeans the {@link super#isCallerCalculationRequired()} will be used.Note that the caller information is only attempted to be calculated when the handler has not been activated. Once activated it's up to the children handlers to determine how the record is processed.
- Parameters:
callerCalculationRequired-trueif the caller information should always be calculated before the record is being placed in the queue
-
isActivated
public final boolean isActivated()Indicates whether or not this handler has been activated.- Returns:
trueif the handler has been activated, otherwisefalse
-