> When I configured logging as in the logback manual in logback.xml:
>
[quoted text clipped - 16 lines]
>
> Hans van der Meer
Well, digging in the sources finally gave the answer.
I turns out (surprise!) that the suggested class to extend, AppenderBase, has a
nonfunctional getLayout() and setLayout(). The first always returns null, the
second one does nothing.
It is a pity the Javadoc gives no hint to this. On the contrary, it says "This
class is used to manage base functionnalities of all appenders." suggesting it
does what it says about these methods.
Solving the problem requires that your own subclass appender does something like:
private Layout layout;
public Layout getLayout(){return layout;}
public setLayout(Layout layout){this.layout = layout;}
and then all will be well.
I am posting this in the hope others who might encounter the problem can find
how to solve it.
Hans van der Meer