[logback-user] Cloning LoggingEvent

Stevo Slavić sslavic at gmail.com
Tue Oct 18 16:55:33 CEST 2011


Migrated from log4j to logback. There was a custom PatternLayout
extensions which processed logging event message before passing on new
logging event with changed message.

Logging event message processing was simple replacement of some
characters. Replaced this with stock PatternLayout and pattern
configured using replace conversion word (see
http://logback.qos.ch/manual/layouts.html#replace )

Regards,
Stevo.

On Wed, Oct 12, 2011 at 10:13 PM, Stevo Slavić <sslavic at gmail.com> wrote:
> Hello Logback users,
>
> Is there a way to clone LoggingEvent?
>
> In a custom PatternLayout implementation I'd like just to change the
> logging event message, so need to create new LoggingEvent with
> everything same as original LoggingEvent except for the message.
>
> Regards,
> Stevo.
>


More information about the Logback-user mailing list