Package org.apache.logging.log4j.web
Class Log4jShutdownOnContextDestroyedListener
- java.lang.Object
-
- org.apache.logging.log4j.web.Log4jShutdownOnContextDestroyedListener
-
- All Implemented Interfaces:
jakarta.servlet.ServletContextListener,java.util.EventListener
public class Log4jShutdownOnContextDestroyedListener extends java.lang.Object implements jakarta.servlet.ServletContextListener
-
-
Field Summary
Fields Modifier and Type Field Description private static intDEFAULT_STOP_TIMEOUTprivate static java.util.concurrent.TimeUnitDEFAULT_STOP_TIMEOUT_TIMEUNITprivate Log4jWebLifeCycleinitializerprivate static java.lang.StringKEY_STOP_TIMEOUTprivate static java.lang.StringKEY_STOP_TIMEOUT_TIMEUNITprivate static LoggerLOGGERprivate jakarta.servlet.ServletContextservletContext
-
Constructor Summary
Constructors Constructor Description Log4jShutdownOnContextDestroyedListener()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcontextDestroyed(jakarta.servlet.ServletContextEvent event)voidcontextInitialized(jakarta.servlet.ServletContextEvent event)
-
-
-
Field Detail
-
DEFAULT_STOP_TIMEOUT
private static final int DEFAULT_STOP_TIMEOUT
- See Also:
- Constant Field Values
-
DEFAULT_STOP_TIMEOUT_TIMEUNIT
private static final java.util.concurrent.TimeUnit DEFAULT_STOP_TIMEOUT_TIMEUNIT
-
KEY_STOP_TIMEOUT
private static final java.lang.String KEY_STOP_TIMEOUT
- See Also:
- Constant Field Values
-
KEY_STOP_TIMEOUT_TIMEUNIT
private static final java.lang.String KEY_STOP_TIMEOUT_TIMEUNIT
- See Also:
- Constant Field Values
-
LOGGER
private static final Logger LOGGER
-
servletContext
private jakarta.servlet.ServletContext servletContext
-
initializer
private Log4jWebLifeCycle initializer
-
-
Method Detail
-
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
-
-