WEB-INF/resources/config/log4j.xml
WEB-INF/resources/config/log4j2.xml
log4j.xml
configuration file, but ship with a log4j2.xml
configuration file.log4j.xml
configuration file, for example because you are upgrading from an older version, you can still use that configuration file, which will take precedence over the new log4j2.xml
file. However we do recommend that you consider moving to a log4j2.xml
configuration file.log4j.xml
file, we recommend that you update the log4j2.xml
configuration file that ships with Orbeon Forms and that you do not create a log4j.xml
.log4j.xml
or log4j2.xml
, you must make sure that you do not have duplicate log file names in the configuration, even if some of them are unused, or Log4j 2.x will complain about that and ignore the configuration. Log4j 1.x did not use to consider this an error, but Log4j 2.x does.log4j2.xml
file, you cannot simply copy the contents of an existing log4j.xml
to log4j2.xml
as the two formats are incompatible! Instead, start with the log4j2.xml
provided, and visit the Log4j 2 configuration online to understand and make changes.<Console>
info
"%date{ISO8601} %-5level %logger{1} - %message%n"
log4j.xml
or log4j2.xml
, it reconfigures Log4j with the specified configuration.WEB-INF/web.xml
with:WEB-INF/resources/config/log4j2.xml
):WEB-INF/resources/config/log4j.xml
):fileName
(Log4j 2.x) or File
(Log4j 1.x) parameter and set an absolute file path to the log file.WEB-INF/resources/config/log4j2.xml
):WEB-INF/resources/config/log4j.xml
):WEB-INF/resources/config/log4j2.xml
):WEB-INF/resources/config/log4j.xml
):info
level. In case this is too much, you can set the level to warning
or even error
. Similarly, for debugging, you can set the level to the more verbose debug
.WEB-INF/resources/config/log4j2.xml
):WEB-INF/resources/config/log4j.xml
):%X{}
syntax in Log4j pattern, prefixing the header name in lower case by orbeon-incoming-http-header-
. For instance, adding the following to your pattern will log the value of the Host
header.