Hi All,
Here is the Problem:
I have couple of
Java Serializable objects, which i am calling from
JSP to display some reports based on some criteria. In the code snippet below, Report is one of the Java Serializable object. Report in turn call some other Java Objects.
Now, it takes me more than 6 minutes to load the JSP page which display reports calling the Report Java Object.
can anybody give me some tips on that??
Here is a code snippet for your reference! Any help would be appreciated!
<der:getreports connection="<%= conn %>" user="<%= admin %>" target="report">
<%
//if (((Report) pageContext.getAttribute("report")).currentStatus() < ReportHistory.ASSIGNED_TO_ENGINEER || (((Report) pageContext.getAttribute("report")).currentStatus() < ReportHistory.COMPLETED && ((Report) pageContext.getAttribute("report")).engineersAvailable(conn)))
if (((Report) pageContext.getAttribute("report")).currentStatus() < ReportHistory.ASSIGNED_TO_ENGINEER || (((Report) pageContext.getAttribute("report")).currentStatus() < ReportHistory.COMPLETED && ((Report) pageContext.getAttribute("report")).engineersAvailable(conn)))
{
recordsFound = true;
%>
<tr>
<td class="resultgrid" bgcolor="#<%= highlight ? "F0F0F0" : "FFFFFF" %>" nowrap="nowrap"><a title="Click to View Original Report" href="javascript: popUpInfo('submission', <%= ((Report) pageContext.getAttribute("report")).getId() %>
; "><%= ((Report) pageContext.getAttribute("report")).getId() %></a> </td>
<td class="resultgrid" bgcolor="#<%= highlight ? "F0F0F0" : "FFFFFF" %>" nowrap="nowrap"><a title="Click to View Contact Info" href="javascript: popUpInfo('contact', <%= ((Report) pageContext.getAttribute("report")).getId() %>
; "><%= ((Report) pageContext.getAttribute("report")).getUser().getFirstName() %> <%= ((Report) pageContext.getAttribute("report")).getUser().getLastName() %></a> </td>
<td class="resultgrid" bgcolor="#<%= highlight ? "F0F0F0" : "FFFFFF" %>" nowrap="nowrap"><a title="Click to View Equipment Info and Problem Description" href="javascript: popUpInfo('equipment', <%= ((Report) pageContext.getAttribute("report")).getId() %>
; "><%= ((Report) pageContext.getAttribute("report")).getEquipment().getName() %></a> </td>
<td class="resultgrid" bgcolor="#<%= highlight ? "F0F0F0" : "FFFFFF" %>" nowrap="nowrap" align="right">
<%
if (((Report) pageContext.getAttribute("report")).engineersAvailable(conn))
{
%>
<%= ((Report) pageContext.getAttribute("report")).currentStatus() >= ReportHistory.ASSIGNED_TO_ENGINEER ? "<a title=\"Click to View Assigned Engineers\" href=\"javascript: popUpInfo('engineers', " + ((Report) pageContext.getAttribute("report")).getId() + "); \">*</a> " : "" %><select name="assign_engineer_<%= ((Report) pageContext.getAttribute("report")).getId() %>" size="1">
<option value="-1" selected="selected">- Choose Engineer -</option>
<der:getengineers connection="<%= conn %>" department="<%= ((Report) pageContext.getAttribute("report")).getDepartment() %>" category="<%= ((Report) pageContext.getAttribute("report")).getEquipment().getCategory() %>" target="engineer">