Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-591

Log4j closes MongoDB connections after the first log message

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • 2.0-rc1
    • 2.0-rc2
    • Appenders
    • None

    Description

      It seems that the AbstractDatabaseManager behavior is now to close the connection after the buffer is flushed (or immediately after a write if there is no buffer). These are the calls to commitAndClose().

      The intended behavior for close() is that it would return a connection to the connection pool. That would make sense for most good database drivers.

      However, the MongoDBProvider simply closes the MongoClient, releasing the entire pool. This means that further attempts to write to the log, after the first time, will fail.

      Attachments

        Activity

          People

            mattsicker Matt Sicker
            emblemparade Tal Liron
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: