aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2013-08-02 19:11:45 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2013-08-02 19:11:45 +1200
commitee14c8ee6e5fe0e5ede618cf954841a131882196 (patch)
treef138dd5efbb4fb89b73bb69027241152e4245f79 /src/org/traccar
parent08eead58823782394f6219561e8f8251cdf17a48 (diff)
downloadtrackermap-server-ee14c8ee6e5fe0e5ede618cf954841a131882196.tar.gz
trackermap-server-ee14c8ee6e5fe0e5ede618cf954841a131882196.tar.bz2
trackermap-server-ee14c8ee6e5fe0e5ede618cf954841a131882196.zip
Fix logging
Diffstat (limited to 'src/org/traccar')
-rw-r--r--src/org/traccar/helper/Log.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/org/traccar/helper/Log.java b/src/org/traccar/helper/Log.java
index 4cd61b933..f79fce79d 100644
--- a/src/org/traccar/helper/Log.java
+++ b/src/org/traccar/helper/Log.java
@@ -27,6 +27,8 @@ import org.apache.log4j.PatternLayout;
public class Log {
+ private static final String LOGGER_NAME = "traccar";
+
private static Logger logger = null;
public static void setupLogger(Properties properties) throws IOException {
@@ -39,7 +41,7 @@ public class Log {
layout, properties.getProperty("logger.file"), "'.'yyyyMMdd");
LogManager.resetConfiguration();
- logger = Logger.getRootLogger();
+ logger = Logger.getLogger(LOGGER_NAME);
logger.addAppender(appender);
logger.setLevel(Level.DEBUG);
}
@@ -47,7 +49,7 @@ public class Log {
public static Logger getLogger() {
if (logger == null) {
- logger = Logger.getRootLogger();
+ logger = Logger.getLogger(LOGGER_NAME);
logger.setLevel(Level.OFF);
}
return logger;