aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src/main/java/com/juick/www/PageTemplates.java
diff options
context:
space:
mode:
authorGravatar Alexander Alexeev2016-11-10 04:50:07 +0700
committerGravatar Vitaly Takmazov2016-11-10 21:41:14 +0300
commit09221ab5695e99b2df1130ea923c39625ec85429 (patch)
tree58c775188d25239a1e32a83f8007e5f1679d49ee /juick-www/src/main/java/com/juick/www/PageTemplates.java
parent705d4f87c97dfa20eb6daa88b93ff124fa401b92 (diff)
using slf4j + logback for logging
Diffstat (limited to 'juick-www/src/main/java/com/juick/www/PageTemplates.java')
-rw-r--r--juick-www/src/main/java/com/juick/www/PageTemplates.java9
1 files changed, 5 insertions, 4 deletions
diff --git a/juick-www/src/main/java/com/juick/www/PageTemplates.java b/juick-www/src/main/java/com/juick/www/PageTemplates.java
index 48176ff9..f8873739 100644
--- a/juick-www/src/main/java/com/juick/www/PageTemplates.java
+++ b/juick-www/src/main/java/com/juick/www/PageTemplates.java
@@ -23,6 +23,8 @@ import com.juick.server.MessagesQueries;
import com.juick.server.TagQueries;
import com.juick.server.UserQueries;
import org.apache.commons.lang3.StringEscapeUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.util.StringUtils;
import ru.sape.Sape;
@@ -36,8 +38,6 @@ import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.List;
-import java.util.logging.Level;
-import java.util.logging.Logger;
import java.util.stream.Collectors;
/**
@@ -46,7 +46,8 @@ import java.util.stream.Collectors;
*/
public class PageTemplates {
- private static final Logger logger = Logger.getLogger(PageTemplates.class.getName());
+ private static final Logger logger = LoggerFactory.getLogger(PageTemplates.class);
+
public static Sape sape = null;
protected static final SimpleDateFormat sdfSQL = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
private static SimpleDateFormat sdfSimple = new SimpleDateFormat("d MMM");
@@ -252,7 +253,7 @@ public class PageTemplates {
ret = sdfFull.format(fulldate);
}
} catch (Exception e) {
- logger.log(Level.SEVERE, "PARSE EXCEPTION: " + fulldate);
+ logger.error("PARSE EXCEPTION: " + fulldate);
}
}
return ret;