- public void init(ServletConfig config) throws ServletException {
- LOG.info("Pnews servlet init " + config.getServletContext().getContextPath());
-
+ public void init(ServletConfig cfg) throws ServletException {
+ LOG.info("Pnews servlet init " + cfg.getServletContext().getContextPath());
+
+ config = new Config();
+ try {
+ config.loadConfig();
+ } catch (UnsupportedEncodingException e) {
+ throw new ServletException(e);
+ }
+
+ provider = new ArticleProvider(config);