stats.shtml revision 742
169N/A## -*- coding: utf-8 -*-
2362N/A##
0N/A## CDDL HEADER START
0N/A##
0N/A## The contents of this file are subject to the terms of the
0N/A## Common Development and Distribution License (the "License").
0N/A## You may not use this file except in compliance with the License.
0N/A##
0N/A## You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
0N/A## or http://www.opensolaris.org/os/licensing.
0N/A## See the License for the specific language governing permissions
0N/A## and limitations under the License.
0N/A##
0N/A## When distributing Covered Code, include this CDDL HEADER in each
0N/A## file and include the License file at usr/src/OPENSOLARIS.LICENSE.
0N/A## If applicable, add the following below this CDDL HEADER, with the
0N/A## fields enclosed by brackets "[]" replaced with your own identifying
0N/A## information: Portions Copyright [yyyy] [name of copyright owner]
2362N/A##
2362N/A## CDDL HEADER END
2362N/A##
0N/A## Copyright 2008 Sun Microsystems, Inc. All rights reserved.
0N/A## Use is subject to license terms.
0N/A##
0N/A<%inherit file="layout.shtml"/>\
0N/A<%page args="g_vars"/>\
0N/A<%
0N/A catalog = g_vars["catalog"]
0N/A config = g_vars["config"]
0N/A%>\
0N/A<%def name="page_title(g_vars)"><%
0N/A return "Depot Statistics"
0N/A%></%def>\
0N/A<div id="yui-main" class="yui-b">
0N/A <div class="yui-gb">
0N/A% if not config.mirror:
0N/A <div class="yui-u first">
0N/A <table class="stats">
0N/A <tr class="first">
0N/A <th class="last" colspan="2">Catalog</th>
0N/A </tr>
169N/A <tr>
0N/A <td class="label">Packages</td>
0N/A <td class="value">${catalog.package_count}</td>
0N/A </tr>
169N/A <tr>
169N/A <td class="label">Last Modified</td>
169N/A<%
169N/A # XXX Is this UTC or local?
169N/A lm = catalog.last_modified.replace(microsecond=0)
169N/A%>
0N/A <td class="value">${lm}</td>
169N/A </tr>
0N/A </table>
169N/A </div>
169N/A% endif
169N/A <div class="yui-u">
0N/A <table class="stats">
169N/A <tr class="first">
0N/A <th class="last" colspan="2">Depot</th>
0N/A </tr>
0N/A <tr>
0N/A <td class="label">Files served by filelist</td>
0N/A <td class="value">${config.filelist_file_requests}</td>
169N/A </tr>
169N/A% if not config.mirror:
169N/A <tr>
169N/A <td class="label">In-flight Transactions</td>
169N/A <td class="value">${config.in_flight_transactions}</td>
0N/A </tr>
169N/A% endif
169N/A </table>
169N/A </div>
169N/A <div class="yui-u">
169N/A <table class="stats">
169N/A <tr class="first">
169N/A <th class="last" colspan="2">Operations</th>
0N/A </tr>
0N/A% if not config.mirror:
<tr>
<td class="label">catalog</td>
<td class="value">${config.catalog_requests}</td>
</tr>
% endif
<tr>
<td class="label">file</td>
<td class="value">${config.file_requests}</td>
</tr>
<tr>
<td class="label">filelist</td>
<td class="value">${config.filelist_requests}</td>
</tr>
% if not config.mirror:
<tr>
<td class="label">manifest</td>
<td class="value">${config.manifest_requests}</td>
</tr>
<tr>
<td class="label">rename</td>
<td class="value">${config.rename_requests}</td>
</tr>
% endif
</table>
</div>
</div>
</div>