Remove call to FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp from VitroHttpServlet, since was getting called more than once per request (since there are multiple servlets that are called for a single request). Use calls from the jsps instead.

This commit is contained in:
rjy7 2010-06-02 17:29:12 +00:00
parent 0c588768db
commit 74297a14af
3 changed files with 3 additions and 8 deletions

View file

@ -6,7 +6,7 @@
<% <%
// If the request was for a jsp rather than a servlet, we didn't get these yet. // If the request was for a jsp rather than a servlet, we didn't get these yet.
// This is here as a safety net. We should have gotten the values in identity.jsp, // This is here as a safety net. We should have gotten the values in identity.jsp,
// since it's the first one we hit. // since it's the first jsp we hit.
String footer = (String) request.getAttribute("ftl_footer"); String footer = (String) request.getAttribute("ftl_footer");
if (footer == null) { if (footer == null) {
FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp(request, response); FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp(request, response);

View file

@ -4,12 +4,7 @@
<%@ page import="edu.cornell.mannlib.vitro.webapp.controller.freemarker.FreeMarkerHttpServlet" %> <%@ page import="edu.cornell.mannlib.vitro.webapp.controller.freemarker.FreeMarkerHttpServlet" %>
<% <%
// If the request was for a jsp rather than a servlet, we didn't get these yet.
String identity = (String) request.getAttribute("ftl_identity");
if (identity == null) {
FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp(request, response); FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp(request, response);
}
%> %>
${ftl_identity} ${ftl_identity}

View file

@ -7,7 +7,7 @@
<% <%
// If the request was for a jsp rather than a servlet, we didn't get these yet. // If the request was for a jsp rather than a servlet, we didn't get these yet.
// This is here as a safety net. We should have gotten the values in identity.jsp, // This is here as a safety net. We should have gotten the values in identity.jsp,
// since it's the first one we hit. // since it's the first jsp we hit.
String menu = (String) request.getAttribute("ftl_menu"); String menu = (String) request.getAttribute("ftl_menu");
if (menu == null) { if (menu == null) {
FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp(request, response); FreeMarkerHttpServlet.getFreeMarkerComponentsForJsp(request, response);