logback / LOGBACK-1725 [Open]
RollingFileAppender.start causes ConcurrentModificationException

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

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-1725

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

David Otto created this issue on 17/Feb/23 1:50 PM
Summary:              RollingFileAppender.start causes 
ConcurrentModificationException
Issue Type:           Bug
Assignee:             Logback dev list
Created:              17/Feb/23 1:50 PM
Environment:
  In our application we add and remove appenders dynamically. We postpone the 
`.start()` call until the first messages arrives to avoid empty files.
  
  There might be more than one thread calling start() on the same RFA
  
  We got this error:
  
   
  {code:java}
  java.util.ConcurrentModificationException: null
          at 
java.base/java.util.HashMap$HashIterator.nextNode(HashMap.java:1597)
          at java.base/java.util.HashMap$EntryIterator.next(HashMap.java:1630)
          at java.base/java.util.HashMap$EntryIterator.next(HashMap.java:1628)
          at 
ch.qos.logback.core.rolling.RollingFileAppender.innerCheckForFileNamePatternCollisionInPreviousRFA(RollingFileAppender.java:135)
          at 
ch.qos.logback.core.rolling.RollingFileAppender.checkForCollisionsInPreviousRollingFileAppenders(RollingFileAppender.java:121)
          at 
ch.qos.logback.core.rolling.RollingFileAppender.start(RollingFileAppender.java:62)
  {code}
   
  is RollingFileAppender.start() supposed to be thread safe?
Priority:             Major
Reporter:             David otto


==============================
 This message was sent by Atlassian Jira (v8.8.0#808000-sha1:e2c7e59)

_______________________________________________
logback-dev mailing list
logback-dev@qos.ch
https://mailman.qos.ch/cgi-bin/mailman/listinfo/logback-dev

Reply via email to