[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.technology.ajdt] Re: AspectJ Log4J and log4j.appender.dest1.layout.ConversionPattern= %l%n%m%n

Hello Andrew,

What were you expecting to see?
I try to use AspectJ to trace Java code source.
What I am expecting to do, is to do Jump-to-code aware, the trace generated by AspectJ into the Eclipse console.


With Log4J if you do :

package usingLog4jToolkit;

import org.apache.log4j.Logger;

//Listing 5.5 A test class

public class Test {
	final static Logger log = Logger.getLogger("test");
	public static void main(String[] args) {

		log.info("Start Program");
etc

With this log4j.properties :
log4j.rootCategory=DEBUG, dest1
log4j.appender.dest1=org.apache.log4j.ConsoleAppender
log4j.appender.dest1.layout=org.apache.log4j.PatternLayout
log4j.appender.dest1.layout.ConversionPattern= %l%n%m%n

You have this outout into the Eclipse console windows :

usingLog4jToolkit.Test.main(Test.java:11)
Start Program

And if you click to (Test.java:11), you jump into the Java code :
		log.info("Start Program");

What I try to do is the same thing with AspectJ

Regards,

Pierre8r