From bad2718b1b85d806221fce52c76fa1d388993396 Mon Sep 17 00:00:00 2001 From: Alexander Alexeev Date: Wed, 7 Dec 2016 18:53:37 +0700 Subject: singleton java 8 date formatters --- juick-rss/src/main/java/com/juick/rss/Main.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'juick-rss/src/main/java') diff --git a/juick-rss/src/main/java/com/juick/rss/Main.java b/juick-rss/src/main/java/com/juick/rss/Main.java index adb20a0d..8d247465 100644 --- a/juick-rss/src/main/java/com/juick/rss/Main.java +++ b/juick-rss/src/main/java/com/juick/rss/Main.java @@ -18,8 +18,10 @@ package com.juick.rss; import com.juick.Message; +import com.juick.Tag; import com.juick.server.MessagesQueries; import com.juick.server.UserQueries; +import com.juick.util.DateFormattersHolder; import com.juick.util.MessageUtils; import org.apache.commons.dbcp2.BasicDataSource; import org.apache.commons.lang3.StringEscapeUtils; @@ -33,7 +35,6 @@ import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.io.PrintWriter; -import java.text.SimpleDateFormat; import java.util.Date; import java.util.List; import java.util.Properties; @@ -44,7 +45,6 @@ import java.util.Properties; @WebServlet(name = "Main", urlPatterns = {"/"}) public class Main extends HttpServlet { - private static final SimpleDateFormat sdfRSS = new SimpleDateFormat("EEE, d MMM yyyy HH:mm:ss Z"); JdbcTemplate sql; @Override @@ -131,19 +131,19 @@ public class Main extends HttpServlet { out.print("