I don't know exactly what you mean by inheriting a logging configuration, but log4j2 supports XInclude for XML configurations. I hope that is useful.
How to inherit log4j configuration xml?
Frage
I have a log4j2.xml
that performs basic webservice logging. As I want to include the webservice project as dependency within another project, I'd like to inherit the logging configuration.
<?xml version="1.0" encoding="UTF-8"?>
<Configuration>
<Appenders>
<RollingFile name="rolling">
...
</RollingFile>
</Appenders>
<Loggers>
<Root level="all">
<AppenderRef ref="rolling />
</Root>
</Loggers>
</Configuration>
As I did not find a way so far to inherit this config. Is it impossible?
Lösung
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow