I'm in favor of the two interfaces suggested but I wanted to point out
that the current implementation of SocketAppender could not be changed
in a compatible way to implement EncoderAware because it is currently
using a stream of serialized objects instead of byte[] for each object
(using a
Maarten Bosteels wrote:
interface LayoutAware extends Appender;
interface EncoderAware extends Appender;
I don't understand.
In my opinion LayoutAware and EncoderAware should be standalone
interface with just a getter and a setter, and not extend Appender.
Yes, obviously.
All appe
On Fri, Feb 13, 2009 at 3:25 PM, Ceki Gulcu wrote:
>
> Hi Maarteen,
>
> I really like the idea of pluggable encoders.
Great.
> Putting UnsyncronizedAppenderBase aside for a second, I could imagine the
> following class hierarchy:
>
> interface LayoutAware extends Appender;
> interface Encoder
Hi Maarteen,
I really like the idea of pluggable encoders. Putting UnsyncronizedAppenderBase
aside for a second, I could imagine the following class hierarchy:
interface LayoutAware extends Appender;
interface EncoderAware extends Appender;
abstract class AppenderBase implements Appender;
abs
Hello,
I agree with Joern, it would be cleaner to have a LayoutAware interface, and
only appenders that use a Layout should implement it.
The way it is now, people can set a layout on the SocketAppender, they don't
get an exception, but the layout would never be used.
I can understand the "histor
On 09.02.2009, at 23:15, Ceki Gulcu wrote:
Hello Joern,
At an earlier time, certain classes expected the Appender interface
to have a setter/getter for the layout property.
AbstractLayoutAction is one such class. However, it is no longer
used. (I just removed it.)
Oh, I see, "for hi
Hello Joern,
At an earlier time, certain classes expected the Appender interface to have a
setter/getter for the layout property. AbstractLayoutAction is one such class.
However, it is no longer used. (I just removed it.)
Many logback appenders do not require a layout and can have their layo
Hi Ceki,
the only thing that I don't understand is why Appender requires a
layout at all.
It would by cleaner if there was a sub-interface, e.g.
LayoutAwareAooender (just a spontaneous suggestion), that extended
Appender and would add said methods.
Some appenders, like SocketAppender or som
Hello all,
While working on chapter 11, migration of log4j appenders to
logback-classic, it occured to me that the current way AppenderBase
implements its layout setter and getter can be confusing. Here is the
relevant code:
abstract public class AppenderBase extends ContextAwareBase implements