[
https://issues.apache.org/jira/browse/LOG4J2-2624?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17278311#comment-17278311
]
ASF subversion and git services commented on LOG4J2-2624:
---------------------------------------------------------
Commit 516756119ff74cb5b4bcbea425bf6b26ec630f63 in logging-log4j2's branch
refs/heads/release-2.x from perry2of5
[ https://gitbox.apache.org/repos/asf?p=logging-log4j2.git;h=5167561 ]
LOG4J2-1606 LOG4J2-2624 Add flag to disable automatic log4j shutdown in
log4j-web. (#463)
Added flag to control auto-shutdown of Log4j when
Log4jServletContainerInitializer is used for a servlet 3+ deployment.
Added "Log4jShutdownOnContextDestroyedListener", a
ServletContextListener, to shutdown log4j cleanly when
contextDestroyed is called. Assuming this ServletContextListener is
the very first listener registered in the web application's web.xml,
then log4j will be shut down after all other components are shut down.
Log4jShutdownOnContextDestroyedListener should only be used when
auto-shutdown is disabled in Log4jServletContainerInitializer.
> ${web:rootDir} not working in weblogic 12c
> ------------------------------------------
>
> Key: LOG4J2-2624
> URL: https://issues.apache.org/jira/browse/LOG4J2-2624
> Project: Log4j 2
> Issue Type: Bug
> Affects Versions: 2.11.0
> Reporter: gaurav
> Priority: Blocker
>
> The web lookup - ${web:rootDir} seems to cause problems on weblogic 12c
> deployment.
> I suspect that the _*web-lookup plugin is not initialized*_ when weblogic
> requests the logger at the start of deployment and is unable to create the
> file.
> What I've done -
> *1. Added slf4j in weblogic preferred packages of weblogic.xml.*
> <wls:package-name>org.slf4j.*</wls:package-name>
> *2. log4j-web dependency is present in classpath.*
> *3.web.xml contains following:-*
> <context-param>
> <param-name>isLog4jAutoInitializationDisabled</param-name>
> <param-value>true</param-value>
> </context-param>
> <listener>
>
> <listener-class>org.apache.logging.log4j.web.Log4jServletContextListener</listener-class>
> </listener>
> <filter>
> <filter-name>log4jServletFilter</filter-name>
>
> <filter-class>org.apache.logging.log4j.web.Log4jServletFilter</filter-class>
> </filter>
> <filter-mapping>
> <filter-name>log4jServletFilter</filter-name>
> <url-pattern>/*</url-pattern>
> <dispatcher>REQUEST</dispatcher>
> <dispatcher>FORWARD</dispatcher>
> <dispatcher>INCLUDE</dispatcher>
> <dispatcher>ERROR</dispatcher>
> </filter-mapping>
> *Note - Log4jServletContextListener is placed before all listeners.
> -Have attached stacktrace for your reference.
> [^stacktrace.txt]
> Please assist.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)