[logback-dev] [JIRA] Updates for LOGBACK-1672: Unable to set delay in DefaultShutdownHook with logback 1.3.0
QOS.CH (JIRA)
noreply-jira at qos.ch
Fri Sep 2 12:43:00 CEST 2022
logback / LOGBACK-1672 [Open]
Unable to set delay in DefaultShutdownHook with logback 1.3.0
==============================
Here's what changed in this issue in the last few minutes.
This issue has been created
This issue is now assigned to you.
View or comment on issue using this link
https://jira.qos.ch/browse/LOGBACK-1672
==============================
Issue created
------------------------------
Juan Pablo Santos RodrÃguez created this issue on 02/Sep/22 12:30 PM
Summary: Unable to set delay in DefaultShutdownHook with logback 1.3.0
Issue Type: Bug
Assignee: Logback dev list
Components: logback-core
Created: 02/Sep/22 12:30 PM
Priority: Major
Reporter: Juan Pablo Santos RodrÃguez
Description:
With logback 1.3.0, registering a shutdownHook as
{code}
...
<shutdownHook class="ch.qos.logback.core.hook.DefaultShutdownHook">
<delay>2000</delay> <!-- allow database connections, if any, to end committing data to database -->
</shutdownHook>
{code}
yields on status manager:
{code}
12:24:15,117 |-INFO in ch.qos.logback.core.model.processor.ShutdownHookModelHandler - Registeting shuthown hook with JVM runtime.
12:24:15,121 |-WARN in ch.qos.logback.core.model.processor.ImplicitModelHandler - Ignoring unkown property [delay] in [ch.qos.logback.classic.LoggerContext]
{code}
with default delay (0) being applied, whereas the (almost) same configuration for logback 1.2.11:
{code}
...
<shutdownHook class="ch.qos.logback.core.hook.DelayingShutdownHook">
<delay>2000</delay>
</shutdownHook>
{code}
works ok. Small nitpick: note that the class changed name between versions, so migrations to logback 1.3.0 containing that hook have to rename/remove the class attribute on the shutdownHook, thus migration isn't simply replacing jars.
==============================
This message was sent by Atlassian Jira (v8.8.0#808000-sha1:e2c7e59)
More information about the logback-dev
mailing list