Martin Desruisseaux ha scritto: > A way to redirect java logging to Apache's commons logging has been commited > on > trunk as of revision 21736. I did a simple test on my machine and it seem to > work, but I would appreciate a test in a real world environment from someone > using Log4J (for example). > > The logging can be redirected by invoking one of the following methods: > > import org.geotools.util.Logging; > > ... > > Logging.GEOTOOLS.redirectToCommonsLogging(); > // Redirect only log records in the "org.geotools" namespace. > // Other log records (e.g. the ones in "java.awt" namespace) > // are still send to the usual java logging handlers. > > // or > > Logging.ALL.redirectToCommonsLogging(); > // Redirect all java log records to commons logging, including > // the one in non-geotools namespace like "java.awt". > > > In current version, one of the above methods must be invoked at startup time. > I > have not deeply investigated how to make such configuration automatic. I may > investigate harder if feedback said that invoking a method a startup time is > not > praticable.
I guess it should be practical enough... since we defined our "way" of forwarding stuff to other loggers, I would have preferred a direct log4j adapter thought :-) (commons was the way for getting logging independence, you suggested another that basically replaces it). Do you see difficulties in coding a log4j specific one? I can code it myself, no problem. Cheers Andrea ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Geotools-devel mailing list Geotools-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-devel