Hi<div><br></div><div>Is it possible to configure theĆ SiftingAppender to use parameters from MDC other than the discriminator ?</div><div><br></div><div>I'd like to achive the following :</div><div>in java:</div><div><div>
<span class="Apple-tab-span" style="white-space:pre"> </span>MDC.put("logger", loggerName);</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>MDC.put("file", fileName);</div></div>
<div><span class="Apple-tab-span" style="white-space: pre; "> </span>MDC.put("pattern", pattern);</div><div><br></div><div>in config:</div><div><br></div><div><div><span class="Apple-tab-span" style="white-space:pre"> </span><appender name="SIFT" class="ch.qos.logback.classic.sift.SiftingAppender"></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span><discriminator></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><Key>logger</Key></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><DefaultValue>default</DefaultValue></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span></discriminator></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><sift></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><appender name="FILE-${logger}" class="ch.qos.logback.core.FileAppender"></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span><File>${file}</File></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><Append>true</Append></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><Encoding>UTF-8</Encoding></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span><BufferedIO>true</BufferedIO></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><ImmediateFlush>true</ImmediateFlush></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span><layout class="ch.qos.logback.classic.PatternLayout"></div><div><span class="Apple-tab-span" style="white-space:pre"> </span><Pattern>{pattern:-%d [%thread] %level %mdc %logger{35} - %msg%n}</Pattern></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span></layout></div><div><span class="Apple-tab-span" style="white-space:pre"> </span></appender></div><div><span class="Apple-tab-span" style="white-space:pre"> </span></sift></div>
<div><span class="Apple-tab-span" style="white-space:pre"> </span></appender></div></div><div><br></div><div>Thanks</div><div><br></div><div>Gabor Dolla</div><div><br></div>