Provide a default logger, some config settings, and some doc updates.
git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@557 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
parent
b836761104
commit
6ecc43f385
Binary file not shown.
|
|
@ -102,4 +102,20 @@ Users can write to these streams just as they write to System.out and
|
|||
System.err. This output can be redirected to a file using the out,
|
||||
err, and outerr command-line arguments.
|
||||
|
||||
\subsection{Logging}
|
||||
The walkers provide a protected logger instance. Users can adjust the
|
||||
debug level of the walkers using the -l command line option.
|
||||
|
||||
Turning on verbose logging can produce more output than the user
|
||||
really needs. To selectively turn on logging for a class or package,
|
||||
the user can specify a log4j.properties property file from the command
|
||||
line as follows:
|
||||
|
||||
\begin{verbatim}
|
||||
-Dlog4j.configuration=file:///humgen/gsa-scr1/hanna/src/Sting/java/config/log4j.properties
|
||||
\end{verbatim}
|
||||
|
||||
An example log4j.properties file is available in the java/config
|
||||
directory of the subversion repository.
|
||||
|
||||
\end{document}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,10 @@
|
|||
log4j.logger.org.broadinstitute.sting.gatk.walkers.Walker=INFO, walker
|
||||
|
||||
# use this to append walker data to the console only
|
||||
log4j.appender.walker=org.apache.log4j.ConsoleAppender
|
||||
|
||||
# uncomment the following instead for writing debug info to a file called walker.log
|
||||
#log4j.appender.walker=org.apache.log4j.FileAppender
|
||||
#log4j.appender.walker.File=walker.log
|
||||
#log4j.appender.walker.layout=org.apache.log4j.PatternLayout
|
||||
#log4j.appender.walker.layout.ConversionPattern=%r [%t] %-5p %c - %m%n
|
||||
|
|
@ -8,6 +8,7 @@ import java.util.List;
|
|||
import org.broadinstitute.sting.gatk.GenomeAnalysisTK;
|
||||
import org.broadinstitute.sting.utils.GenomeLoc;
|
||||
import org.broadinstitute.sting.utils.Pair;
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
/**
|
||||
* Created by IntelliJ IDEA.
|
||||
|
|
@ -19,6 +20,8 @@ import org.broadinstitute.sting.utils.Pair;
|
|||
public abstract class Walker<MapType, ReduceType> {
|
||||
// TODO: Can a walker be templatized so that map and reduce live here?
|
||||
|
||||
protected static Logger logger = Logger.getLogger(Walker.class);
|
||||
|
||||
/**
|
||||
* A stream for writing normal (non-error) output. System.out by default.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in New Issue