Removed HTML cache for organizations and services metrics pages.
The combinatorial is too large: - 48 pages by item - 100 organizations + 300 services = 400 items - => ~20 000 pages - 200kB/page - => 4GB in memory - ==> no way. Metrics pages are so numerous than they have to build on demand.
This commit is contained in:
parent
fba9e6a7ab
commit
dc73cd79f5
8 changed files with 176 additions and 216 deletions
|
@ -66,9 +66,6 @@ public class MetricGenericPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Organization > Metrics > Summary");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -91,9 +88,7 @@ public class MetricGenericPage extends HttpServlet
|
|||
trail.add("Métriques", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/");
|
||||
trail.add("Génériques", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/generic.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -64,9 +64,6 @@ public class MetricSpecificPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Organization > Metrics > Specific");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -89,9 +86,7 @@ public class MetricSpecificPage extends HttpServlet
|
|||
trail.add("Métriques", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/");
|
||||
trail.add("Spécifiques", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/specific.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -66,9 +66,6 @@ public class MetricSummaryPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Organization > Metrics > Summary");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -91,9 +88,7 @@ public class MetricSummaryPage extends HttpServlet
|
|||
trail.add("Métriques", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/");
|
||||
trail.add("Résumé", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/summary.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -65,9 +65,6 @@ public class MetricWebPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Organization > Metrics > Web");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -90,9 +87,7 @@ public class MetricWebPage extends HttpServlet
|
|||
trail.add("Métriques", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/");
|
||||
trail.add("Web", "/federation/organizations/" + organization.getTechnicalName() + "/metrics/web.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -67,9 +67,6 @@ public class MetricGenericPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Service > MetricGenericPage");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -98,9 +95,7 @@ public class MetricGenericPage extends HttpServlet
|
|||
trail.add("Générique", "/federation/organizations/" + organization.getTechnicalName() + "/services/" + service.getTechnicalName()
|
||||
+ "/metrics/generic.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -67,9 +67,6 @@ public class MetricSpecificPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Service > MetricGenericPage");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
Service service = StatoolInfosWeb.instance().getServiceFromPathinfo(request.getPathInfo() + "?" + request.getQueryString());
|
||||
|
@ -98,9 +95,7 @@ public class MetricSpecificPage extends HttpServlet
|
|||
trail.add("Spécifique", "/federation/organizations/" + organization.getTechnicalName() + "/services/" + service.getTechnicalName()
|
||||
+ "/metrics/specific.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -67,9 +67,6 @@ public class MetricSummaryPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Service > MetricSummaryPage");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -98,9 +95,7 @@ public class MetricSummaryPage extends HttpServlet
|
|||
trail.add("Résumé", "/federation/organizations/" + organization.getTechnicalName() + "/services/" + service.getTechnicalName()
|
||||
+ "/metrics/summary.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
|
@ -67,9 +67,6 @@ public class MetricWebPage extends HttpServlet
|
|||
{
|
||||
logger.info("PAGE Service > MetricGenericPage");
|
||||
|
||||
String html = StatoolInfosWeb.instance().getHtmlCache().get(request);
|
||||
if (html == null)
|
||||
{
|
||||
// Get parameters.
|
||||
// ===============
|
||||
ViewMenu viewMenu = ViewMenu.valueFrom(request.getParameter("view"));
|
||||
|
@ -98,9 +95,7 @@ public class MetricWebPage extends HttpServlet
|
|||
trail.add("Web", "/federation/organizations/" + organization.getTechnicalName() + "/services/" + service.getTechnicalName()
|
||||
+ "/metrics/web.xhtml");
|
||||
|
||||
html = WebCharterView.build(headerView, contentView, trail);
|
||||
StatoolInfosWeb.instance().getHtmlCache().put(request, html);
|
||||
}
|
||||
String html = WebCharterView.build(headerView, contentView, trail);
|
||||
|
||||
// Display page.
|
||||
response.setContentType("application/xhtml+xml; charset=UTF-8");
|
||||
|
|
Loading…
Reference in a new issue