[logback-dev] [JIRA] Updates for LOGBACK-1727: Logback: After upgrading to 1.3.6 with SLF4J 2.0.4, logs are being written to unknown.log file.

logback developers list logback-dev at qos.ch
Wed Mar 22 14:42:00 CET 2023


logback / LOGBACK-1727 [Open]
Logback: After upgrading to 1.3.6 with SLF4J 2.0.4, logs are being written to unknown.log file.

==============================

Here's what changed in this issue in the last few minutes.

This issue has been created
This issue is now assigned to you.


View or comment on issue using this link
https://jira.qos.ch/browse/LOGBACK-1727

==============================
 Issue created
------------------------------

Lakshmikanth Reddy created this issue on 22/Mar/23 14:31

Summary:              Logback: After upgrading to 1.3.6 with SLF4J 2.0.4, logs are being written to unknown.log file.
Issue Type:           Bug
Affects Versions:     1.3.6
Assignee:             Logback dev list
Components:           logback-core
Created:              22/Mar/23 14:31
Labels:               siftingAppender
Priority:             Major
Reporter:             Lakshmikanth Reddy
Description:
  Hi Team,
  
   
  
  After upgrading the logback-classic and logback-core to 1.3.6 along with SLF4J to 2.0.4, the logs are being written to unknown.log file. 
  
  Our config looks exactly like below. 
  {code:java}
  <configuration> <appender name="SIFT" class="ch.qos.logback.classic.sift.SiftingAppender">
        <discriminator class="ch.qos.logback.classic.sift.JNDIBasedContextDiscriminator">
           <DefaultValue>unknown</DefaultValue>
        </discriminator>
        <sift>
           <appender name="FILE-${contextName}" class="ch.qos.logback.core.rolling.RollingFileAppender">
              <File>${catalina.base}/logs/${contextName}.log</File>
              <append>true</append>
              <immediateFlush>true</immediateFlush>
              <rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
                 <fileNamePattern>${catalina.base}/logs/${contextName}.%i.log.zip</fileNamePattern>
                 <minIndex>1</minIndex>
                 <maxIndex>3</maxIndex>
              </rollingPolicy>
              <triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
                 <maxFileSize>20MB</maxFileSize>
              </triggeringPolicy>
              <encoder>
                 <pattern>%d{yyyy-MM-dd HH:mm:ss.SSS}|%-5level|${HOSTNAME}|%msg ||%class:%line %xException{full} %n</pattern>
              </encoder>
           </appender>
        </sift>
      </appender>
     <root level="INFO">
        <appender-ref ref="SIFT" />
     </root> </configuration> {code}
  
  Our previous version was: logback: 1.2.11 with SLF4J at version 1.7.36.
  
  Note: All the required config described in the documentation for JNDI is as is and has not changed. 
  
  
  
  Any pointers to resolve this issue would be great help.
  
   
  
  Thanks,
  
  Lakshmikanth 
  
   


==============================
 This message was sent by Atlassian Jira (v9.6.0#960000-sha1:a3ee8af)



More information about the logback-dev mailing list