[logback-user] Logback-user Digest, Vol 31, Issue 15

David Tkaczyk djt69b at gmail.com
Wed Apr 30 13:04:13 CEST 2014


Look at documentation for logger config.  additivity = false...  Or look
for DuplicateMessageFilter...  Or write your own filter.
 On Apr 30, 2014 6:00 AM, <logback-user-request at qos.ch> wrote:

> Send Logback-user mailing list submissions to
>         logback-user at qos.ch
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         http://mailman.qos.ch/mailman/listinfo/logback-user
> or, via email, send a message with subject or body 'help' to
>         logback-user-request at qos.ch
>
> You can reach the person managing the list at
>         logback-user-owner at qos.ch
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Logback-user digest..."
>
> Today's Topics:
>
>    1. How to get a unique content rollingFileAppender? (hax0r at sina.com)
>
>
> ---------- Forwarded message ----------
> From: <hax0r at sina.com>
> To: "logback-user" <logback-user at qos.ch>
> Cc:
> Date: Wed, 30 Apr 2014 15:23:42 +0800
> Subject: [logback-user] How to get a unique content rollingFileAppender?
>
> I want such a rollingFileAppneder:
>
> Before appending new line to the current log file, the logger will check:
> if there is any same line in the current log file, it will not write the
> same content to the file.
>
>
> I can not find such a file appender, so I want to customize it:
>
>
> Firstly, I want to create a class extends the RollingFileAppneder, but I
> find that the field which point to current file in RollingFileAppneder is
> "friendly", I can not get the field in my own class.
>
>
> There is an stupid option: I copy all the codes in the
> RollingFileAppneder, and changed some logic in the append part.
>
>
> Is there a elgant way to get such a unique content rollingFileAppender?
>
>
>
>
>
> _______________________________________________
> Logback-user mailing list
> Logback-user at qos.ch
> http://mailman.qos.ch/mailman/listinfo/logback-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.qos.ch/pipermail/logback-user/attachments/20140430/53e027d2/attachment.html>


More information about the Logback-user mailing list