From: Brad <bra...@us...> - 2005-10-21 03:24:49
|
Update of /cvsroot/archive-access/archive-access/projects/wayback/src/java/org/archive/wayback/servletglue In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14129/src/java/org/archive/wayback/servletglue Modified Files: RequestFilter.java WBQueryUIServlet.java WBReplayUIServlet.java Log Message: Heavy modification of configuration to be Context-level, instead of Servlet-level, which dramatically reduces configuration redundancy. Cleaned up IndexPipeline, moved a few classes around, added a really simple JSP to view the Index and Merge queue sizes, and a filter, which both allows the index thread to start with the context, and allows access to the jsp. Index: WBQueryUIServlet.java =================================================================== RCS file: /cvsroot/archive-access/archive-access/projects/wayback/src/java/org/archive/wayback/servletglue/WBQueryUIServlet.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** WBQueryUIServlet.java 20 Oct 2005 00:40:41 -0000 1.3 --- WBQueryUIServlet.java 21 Oct 2005 03:24:40 -0000 1.4 *************** *** 29,32 **** --- 29,33 ---- import javax.servlet.ServletConfig; + import javax.servlet.ServletContext; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; *************** *** 66,70 **** p.put(key, c.getInitParameter(key)); } ! try { wayback.init(p); --- 67,76 ---- p.put(key, c.getInitParameter(key)); } ! ServletContext sc = c.getServletContext(); ! for (Enumeration e = sc.getInitParameterNames(); e.hasMoreElements();) { ! String key = (String) e.nextElement(); ! p.put(key, sc.getInitParameter(key)); ! } ! try { wayback.init(p); Index: WBReplayUIServlet.java =================================================================== RCS file: /cvsroot/archive-access/archive-access/projects/wayback/src/java/org/archive/wayback/servletglue/WBReplayUIServlet.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** WBReplayUIServlet.java 20 Oct 2005 00:40:41 -0000 1.3 --- WBReplayUIServlet.java 21 Oct 2005 03:24:40 -0000 1.4 *************** *** 29,32 **** --- 29,33 ---- import javax.servlet.ServletConfig; + import javax.servlet.ServletContext; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; *************** *** 65,68 **** --- 66,74 ---- p.put(key, c.getInitParameter(key)); } + ServletContext sc = c.getServletContext(); + for (Enumeration e = sc.getInitParameterNames(); e.hasMoreElements();) { + String key = (String) e.nextElement(); + p.put(key, sc.getInitParameter(key)); + } try { Index: RequestFilter.java =================================================================== RCS file: /cvsroot/archive-access/archive-access/projects/wayback/src/java/org/archive/wayback/servletglue/RequestFilter.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** RequestFilter.java 19 Oct 2005 01:22:37 -0000 1.2 --- RequestFilter.java 21 Oct 2005 03:24:40 -0000 1.3 *************** *** 55,59 **** private static final String WMREQUEST_ATTRIBUTE = "wmrequest.attribute"; ! private static final String REQUEST_PARSER_CLASS = "requestParser.class"; private static final String HANDLER_URL = "handler.url"; --- 55,59 ---- private static final String WMREQUEST_ATTRIBUTE = "wmrequest.attribute"; ! private static final String REQUEST_PARSER_CLASS = "requestparser.class"; private static final String HANDLER_URL = "handler.url"; |