2006-07-19 17:58:23 -04:00
|
|
|
<%@ page contentType="text/xml; charset=utf-8" pageEncoding="UTF-8" language="java" %>
|
2006-11-09 18:13:58 -05:00
|
|
|
<%--
|
|
|
|
Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
contributor license agreements. See the NOTICE file distributed with
|
|
|
|
this work for additional information regarding copyright ownership.
|
|
|
|
The ASF licenses this file to You under the Apache License, Version 2.0
|
|
|
|
(the "License"); you may not use this file except in compliance with
|
|
|
|
the License. You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
--%>
|
2006-02-22 00:53:23 -05:00
|
|
|
<%@ page import="org.apache.solr.core.SolrInfoMBean,
|
2007-06-14 22:16:07 -04:00
|
|
|
org.apache.solr.common.util.NamedList,
|
2006-02-22 00:53:23 -05:00
|
|
|
java.util.Date,
|
|
|
|
java.util.Map"%>
|
2006-02-14 14:36:06 -05:00
|
|
|
<?xml-stylesheet type="text/xsl" href="stats.xsl"?>
|
2006-02-22 00:53:23 -05:00
|
|
|
<%@include file="_info.jsp" %>
|
2006-01-26 00:37:29 -05:00
|
|
|
|
|
|
|
|
|
|
|
<solr>
|
2008-06-30 20:24:25 -04:00
|
|
|
<%
|
|
|
|
if (core.getName() != null) { %>
|
2010-02-12 22:28:07 -05:00
|
|
|
<core><% XML.escapeCharData(core.getName(), out); %></core>
|
2008-06-30 20:24:25 -04:00
|
|
|
<% } %>
|
2010-02-12 22:28:07 -05:00
|
|
|
<schema><% XML.escapeCharData(collectionName, out); %></schema>
|
|
|
|
<host><% XML.escapeCharData(hostname, out); %></host>
|
|
|
|
<now><% XML.escapeCharData(new Date().toString(), out); %></now>
|
|
|
|
<start><% XML.escapeCharData(new Date(core.getStartTime()).toString(), out); %></start>
|
2006-01-26 00:37:29 -05:00
|
|
|
<solr-info>
|
|
|
|
<%
|
|
|
|
for (SolrInfoMBean.Category cat : SolrInfoMBean.Category.values()) {
|
|
|
|
%>
|
|
|
|
<<%= cat.toString() %>>
|
|
|
|
<%
|
2007-09-08 15:03:54 -04:00
|
|
|
Map<String,SolrInfoMBean> reg = core.getInfoRegistry();
|
2006-01-26 00:37:29 -05:00
|
|
|
for (Map.Entry<String,SolrInfoMBean> entry : reg.entrySet()) {
|
|
|
|
String key = entry.getKey();
|
|
|
|
SolrInfoMBean m = entry.getValue();
|
|
|
|
|
|
|
|
if (m.getCategory() != cat) continue;
|
|
|
|
|
|
|
|
NamedList nl = m.getStatistics();
|
|
|
|
if ((nl != null) && (nl.size() != 0)) {
|
|
|
|
String na = "None Provided";
|
|
|
|
String name = (m.getName()!=null ? m.getName() : na);
|
|
|
|
String vers = (m.getVersion()!=null ? m.getVersion() : na);
|
|
|
|
String desc = (m.getDescription()!=null ? m.getDescription() : na);
|
|
|
|
%>
|
|
|
|
<entry>
|
|
|
|
<name>
|
2010-02-12 22:28:07 -05:00
|
|
|
<% XML.escapeCharData(key, out); %>
|
2006-01-26 00:37:29 -05:00
|
|
|
</name>
|
|
|
|
<class>
|
2010-02-12 22:28:07 -05:00
|
|
|
<% XML.escapeCharData(name, out); %>
|
2006-01-26 00:37:29 -05:00
|
|
|
</class>
|
|
|
|
<version>
|
2010-02-12 22:28:07 -05:00
|
|
|
<% XML.escapeCharData(vers, out); %>
|
2006-01-26 00:37:29 -05:00
|
|
|
</version>
|
|
|
|
<description>
|
2010-02-12 22:28:07 -05:00
|
|
|
<% XML.escapeCharData(desc, out); %>
|
2006-01-26 00:37:29 -05:00
|
|
|
</description>
|
|
|
|
<stats>
|
|
|
|
<%
|
|
|
|
for (int i = 0; i < nl.size() ; i++) {
|
|
|
|
%>
|
2010-02-12 22:28:07 -05:00
|
|
|
<stat name="<% XML.escapeAttributeValue(nl.getName(i), out); %>" >
|
|
|
|
<% XML.escapeCharData(nl.getVal(i).toString(), out); %>
|
2006-01-26 00:37:29 -05:00
|
|
|
</stat>
|
|
|
|
<%
|
|
|
|
}
|
|
|
|
%>
|
|
|
|
</stats>
|
|
|
|
</entry>
|
|
|
|
<%
|
|
|
|
}
|
|
|
|
%>
|
|
|
|
<%
|
|
|
|
}
|
|
|
|
%>
|
|
|
|
</<%= cat.toString() %>>
|
|
|
|
<%
|
|
|
|
}
|
|
|
|
%>
|
|
|
|
</solr-info>
|
|
|
|
</solr>
|