https://kotlinlang.org logo
#ktor
Title
# ktor
s

Stefan Peterson

06/30/2020, 11:39 PM
Pretty noob ktor user here. I am trying to set up logging for our production environment to be
INFO
level. For a Logback provider I have
logback-classic
declared as a dependency in my
pom.xml
and set up a
logback.xml
file src > main > resources but when I try to access the default logger in any ApplicationCall context I am still seeing
DEBUG
level logs. My
logback.xml
looks like the following:
Copy code
<configuration>
    <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
        <encoder>
            <pattern>%d{YYYY-MM-dd HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
        </encoder>
    </appender>

    <root level="info">
        <appender-ref ref="STDOUT"/>
    </root>

    <logger name="org.eclipse.jetty" level="INFO"/>
    <logger name="io.netty" level="INFO"/>
    <logger name="ktor.application" level="INFO" />
</configuration>
l

Luis Munoz

07/01/2020, 12:22 AM
Copy code
<configuration debug="true">
try adding debug to see if it is even reading it
5 Views