logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ilya Tepikin <ilya.tepi...@gmail.com>
Subject log4j2 SMTP Appender: include previous messages with another level
Date Fri, 10 Jan 2014 17:29:53 GMT
Hi All,

I'm using log4j2-beta9 and I have the following config (part of it):

        <SMTP name="Mailer" suppressExceptions="false"
              subject="${subject}" to="${receipients}" from="${from}"
              smtpHost="${smtpHost}" smtpPort="${smtpPort}"
              smtpProtocol="${smtpProtocol}" smtpUsername="${smtpUser}"
              smtpPassword="${smtpPassword}" smtpDebug="false"
                <pattern>%d{dd-MM-yyyy HH:mm:ss,SSS} %5p %m%n</pattern>

        <Async name="AsyncMailer">
            <AppenderRef ref="Mailer"/>
        <Root level="info">
            <AppenderRef ref="AsyncMailer" level="error"/>

With this configuration I receive email with just 1 error message.
How can I configure log4j2 to receive 1 error message and N previous
messages with LEVEL=INFO?

Thanks in advance. And thanks for such a great lib!

Ilya Tepikin.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message