Package org.apache.logging.log4j.web
Class Log4jShutdownOnContextDestroyedListener
java.lang.Object
org.apache.logging.log4j.web.Log4jShutdownOnContextDestroyedListener
- All Implemented Interfaces:
jakarta.servlet.ServletContextListener,EventListener
public class Log4jShutdownOnContextDestroyedListener
extends Object
implements jakarta.servlet.ServletContextListener
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final intprivate static final TimeUnitprivate Log4jWebLifeCycleprivate static final Stringprivate static final Stringprivate static final Loggerprivate jakarta.servlet.ServletContext -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcontextDestroyed(jakarta.servlet.ServletContextEvent event) voidcontextInitialized(jakarta.servlet.ServletContextEvent event)
-
Field Details
-
DEFAULT_STOP_TIMEOUT
private static final int DEFAULT_STOP_TIMEOUT- See Also:
-
DEFAULT_STOP_TIMEOUT_TIMEUNIT
-
KEY_STOP_TIMEOUT
- See Also:
-
KEY_STOP_TIMEOUT_TIMEUNIT
- See Also:
-
LOGGER
-
servletContext
private jakarta.servlet.ServletContext servletContext -
initializer
-
-
Constructor Details
-
Log4jShutdownOnContextDestroyedListener
public Log4jShutdownOnContextDestroyedListener()
-
-
Method Details
-
contextInitialized
public void contextInitialized(jakarta.servlet.ServletContextEvent event) - Specified by:
contextInitializedin interfacejakarta.servlet.ServletContextListener
-
contextDestroyed
public void contextDestroyed(jakarta.servlet.ServletContextEvent event) - Specified by:
contextDestroyedin interfacejakarta.servlet.ServletContextListener
-