[logback-user] Logback configuration is coming as null
Debraj Manna
subharaj.manna at gmail.com
Sat Jan 13 06:27:33 CET 2018
Anyone any thoughts? Actually we are thinking of migrating to log back from
log4j. So we want to try logback in one module first. We have quite a few
custom Appenders and layouts in log4j. So we want to do the migration
module by module.
But the current issue that I am getting is preventing me from using logback
in one module and log4j in other modules in the multi module maven project.
On 13-Jan-2018 9:22 AM, "Debraj Manna" <subharaj.manna at gmail.com> wrote:
> I am having a multi module maven project. In some of the modules I want to
> use log4j and in some log back. Is it possible to do so?
>
> On 13-Jan-2018 12:33 AM, "Debraj Manna" <subharaj.manna at gmail.com> wrote:
>
>> Correct restapilayer.logback.xml
>>
>> <?xml version="1.0" encoding="UTF-8"?><configuration debug="true">
>>
>> <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
>> <layout class="ch.qos.logback.classic.PatternLayout">
>> <encoder>
>> %d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{36} - %msg%n
>> </encoder>
>> </layout>
>> </appender>
>>
>> <root level="DEBUG">
>> <appender-ref ref="STDOUT" />
>> </root>
>> </configuration>
>>
>>
>> Logs
>>
>> 18:58:45,418 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Found resource [/home/ubuntu/build-target/restapilayer/restapilayer.logback.xml] at [file:/home/ubuntu/build-target/restapilayer/restapilayer.logback.xml]18:58:45,608 |-INFO in ch.qos.logback.core.joran.action.AppenderAction - About to instantiate appender of type [ch.qos.logback.core.ConsoleAppender]18:58:45,611 |-INFO in ch.qos.logback.core.joran.action.AppenderAction - Naming appender as [CONSOLE]18:58:45,617 |-INFO in ch.qos.logback.core.joran.action.NestedComplexPropertyIA - Assuming default type [ch.qos.logback.classic.encoder.PatternLayoutEncoder] for [encoder] property18:58:45,645 |-INFO in ch.qos.logback.classic.joran.action.RootLoggerAction - Setting level of ROOT logger to DEBUG18:58:45,645 |-INFO in ch.qos.logback.core.joran.action.AppenderRefAction - Attaching appender named [CONSOLE] to Logger[ROOT]18:58:45
>>
>> ...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.qos.ch/pipermail/logback-user/attachments/20180113/0a173537/attachment-0001.html>
More information about the logback-user
mailing list