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

SMTPManager buffer access not synchronized; can result in empty emails

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0-beta4
    • 2.0-beta4
    • Appenders
    • None
    • N/A

    Description

      If multiple error events are logged against the same SMTPAppender/Manager at the same time, one email will contain both error messages, while the second will be empty (no events).

      The original SMTPAppender patch included synchronization against the CyclicBuffer to prevent such simultaneous access from multiple threads. This appears to have been lost in the merge/refactor. Patch (to follow shortly) re-introduces synchronization against the CyclicBuffer in the narrowest possible scope.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            rgoers Ralph Goers
            ssevertson Scott Severtson
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment