Hi,<br><br>i&#39;m implementing a loggin via AspectJ in a Maven project.<br><br>My aspect class is something like this...<br><br><br>public aspect TraceMethodCalls {
<br> <br>    static Marker ASPECTJ_TRACE_ENTER = MarkerFactory.getMarker(&quot;ASPECTJ_TRACE_ENTER&quot;);
<br> <br>    final Logger logger = LoggerFactory.getLogger(TraceMethodCalls.class);
<br>     <br>    TraceMethodCalls() {
<br>    }
<br> <br>    pointcut traceMethods()
<br>        //give me all method calls of every class with every visibility
<br>        : (execution(* *.*(..))
<br>        //give me also constructor calls
<br>        || execution(*.new(..)))
<br>        &amp;&amp; !execution(* toString(..)) &amp;&amp; !execution(* hashCode(..))
<br>        //stop recursion don&#39;t get method calls in this aspect class itself
<br>        &amp;&amp; !within(TraceMethodCalls);
<br> <br>    //advice before: do something before method is really executed
<br>    before() : traceMethods() {
<br>        if (logger.isDebugEnabled()) {
<br>            //get info about captured method and log it
<br>            Signature sig = thisJoinPointStaticPart.getSignature();
<br>            
<br>            logger.trace(ASPECTJ_TRACE_ENTER, &quot;---&gt; [&quot; + sig.toShortString() + &quot;]&quot;);            
<br>            
<br>        }
<br>    }
<br>    
<br>    //advice before: do something before method is really executed
<br>    after() returning (Object o): traceMethods() {
<br>        if (logger.isDebugEnabled()) {
<br>            //get info about captured method and log it
<br>            Signature sig = thisJoinPointStaticPart.getSignature();
<br>            
<br>            logger.trace(ASPECTJ_TRACE_ENTER, &quot;&lt;--- [&quot; + sig.toShortString() + &quot;]&quot;);
<br>            
<br>        }
<br>    }<br><br>and logback appender<br><br><br>   &lt;appender name=&quot;ASPECTJ_TRACE_ENTER&quot; class=&quot;ch.qos.logback.core.rolling.RollingFileAppender&quot;&gt;
<br>        &lt;filter class=&quot;ch.qos.logback.core.filter.EvaluatorFilter&quot;&gt;
<br>            &lt;evaluator class=&quot;ch.qos.logback.classic.boolex.JaninoEventEvaluator&quot;&gt;
<br>                  &lt;expression&gt;
<br>                    (marker != null) &amp;amp;&amp;amp; (marker.contains(&quot;ASPECTJ_TRACE_ENTER&quot;))
<br>                  &lt;/expression&gt;
<br>            &lt;/evaluator&gt;
<br>            &lt;onMatch&gt;ACCEPT&lt;/onMatch&gt;
<br>            &lt;onMismatch&gt;DENY&lt;/onMismatch&gt;                 <br>        &lt;/filter&gt;
<br> <br>        &lt;prudent&gt;${prudent}&lt;/prudent&gt;
<br>  
<br>        &lt;!-- full stacktrace para las excepciones --&gt;
<br>        &lt;encoder class=&quot;ch.qos.logback.classic.encoder.PatternLayoutEncoder&quot;&gt;
<br>            &lt;Pattern&gt;%date %-5level - cn=%contextName - [%thread] - %message%n&lt;/Pattern&gt;
<br>        &lt;/encoder&gt;
<br> <br>        &lt;rollingPolicy class=&quot;ch.qos.logback.core.rolling.TimeBasedRollingPolicy&quot;&gt;
<br>            &lt;FileNamePattern&gt;${USER_HOME}/${backupDir}aspectj.enter_exit.%d${patronRolling}&lt;/FileNamePattern&gt;  
<br>            &lt;MaxHistory&gt;${maxHistory}&lt;/MaxHistory&gt; 
<br>        &lt;/rollingPolicy&gt;
<br>      &lt;/appender&gt;<br><br>I see that that support to NDC is disabled in logback, how could i implement a TAB of this messages without NCD?<br><br>---&gt;Method1<br>------&gt;Method2<br>---------&gt;Method3<br>&lt;---------Method3<br clear="all">
&lt;------Method2<br>&lt;---Method1<br><br><br>Thanks.<br><br>-- <br>Jose Juan Montiel Martinez<br>Eurobits Technologies<br>Calle Musgo 3, 1ยช Planta<br>28023 Madrid<br>T +34-917080300<br>F +34-913077480<br><a href="mailto:josejuan.montiel@eurobits.es">josejuan.montiel@eurobits.es</a><br>
<a href="http://www.eurobits.com">http://www.eurobits.com</a><br>