~slub.team/goobi-indexserver/3.x

« back to all changes in this revision

Viewing changes to solr/webapp/web/admin/index.jsp

  • Committer: Sebastian Meyer
  • Date: 2012-08-03 09:12:40 UTC
  • Revision ID: sebastian.meyer@slub-dresden.de-20120803091240-x6861b0vabq1xror
Remove Lucene and Solr source code and add patches instead
Fix Bug #985487: Auto-suggestion for the search interface

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<%@ page contentType="text/html; charset=utf-8" pageEncoding="UTF-8"%>
2
 
<%--
3
 
 Licensed to the Apache Software Foundation (ASF) under one or more
4
 
 contributor license agreements.  See the NOTICE file distributed with
5
 
 this work for additional information regarding copyright ownership.
6
 
 The ASF licenses this file to You under the Apache License, Version 2.0
7
 
 (the "License"); you may not use this file except in compliance with
8
 
 the License.  You may obtain a copy of the License at
9
 
 
10
 
     http://www.apache.org/licenses/LICENSE-2.0
11
 
 
12
 
 Unless required by applicable law or agreed to in writing, software
13
 
 distributed under the License is distributed on an "AS IS" BASIS,
14
 
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
 
 See the License for the specific language governing permissions and
16
 
 limitations under the License.
17
 
--%>
18
 
 
19
 
<%-- $Id: index.jsp 1089340 2011-04-06 07:49:14Z uschindler $ --%>
20
 
<%-- $Source: /cvs/main/searching/SolrServer/resources/admin/index.jsp,v $ --%>
21
 
<%-- $Name:  $ --%>
22
 
 
23
 
<%@ page import="java.util.Date" %>
24
 
<%@ page import="java.util.List" %>
25
 
<%@ page import="java.util.Collection" %>
26
 
<%@ page import="org.apache.solr.request.SolrRequestHandler"%>
27
 
<%@ page import="org.apache.solr.handler.ReplicationHandler" %>
28
 
 
29
 
<%-- jsp:include page="header.jsp"/ --%>
30
 
<%-- do a verbatim include so we can use the local vars --%>
31
 
<%@include file="header.jsp" %>
32
 
<%boolean replicationhandler = !core.getRequestHandlers(ReplicationHandler.class).isEmpty();%>
33
 
<br clear="all">
34
 
<table>
35
 
 
36
 
<tr>
37
 
  <td>
38
 
        <h3>Solr</h3>
39
 
  </td>
40
 
  <td>
41
 
    <% if (null != core.getSchemaResource()) { %>
42
 
    [<a href="file/?contentType=text/xml;charset=utf-8&file=<%=core.getSchemaResource()%>">Schema</a>]
43
 
    <% }
44
 
       if (null != core.getConfigResource()) { %>
45
 
    [<a href="file/?contentType=text/xml;charset=utf-8&file=<%=core.getConfigResource()%>">Config</a>]
46
 
    <% } %>
47
 
    [<a href="analysis.jsp?highlight=on">Analysis</a>]
48
 
    [<a href="schema.jsp">Schema Browser</a>] <%if(replicationhandler){%>[<a href="replication/index.jsp">Replication</a>]<%}%>
49
 
    <br>
50
 
    [<a href="stats.jsp">Statistics</a>]
51
 
    [<a href="registry.jsp">Info</a>]
52
 
    [<a href="distributiondump.jsp">Distribution</a>]
53
 
    [<a href="ping">Ping</a>]
54
 
    [<a href="logging">Logging</a>]
55
 
  </td>
56
 
</tr>
57
 
 
58
 
<%-- List the cores (that arent this one) so we can switch --%>
59
 
<% org.apache.solr.core.CoreContainer cores = (org.apache.solr.core.CoreContainer)request.getAttribute("org.apache.solr.CoreContainer");
60
 
  if (cores!=null) {
61
 
    Collection<String> names = cores.getCoreNames();
62
 
    if (names.size() > 1) {%><tr><td><strong>Cores:</strong><br></td><td><%
63
 
    String url = request.getContextPath();
64
 
    for (String name : names) {
65
 
      String lname = name.length()==0 ? cores.getDefaultCoreName() : name; // use the real core name rather than the default
66
 
      if(name.equals(core.getName())) {
67
 
        %>[<%=lname%>]<%
68
 
      } else {
69
 
        %>[<a href="<%=url%>/<%=lname%>/admin/"><%=lname%></a>]<%
70
 
      }
71
 
  }%></td></tr><%
72
 
}}%>
73
 
 
74
 
<tr>
75
 
  <td>
76
 
    <strong>App server:</strong><br>
77
 
  </td>
78
 
  <td>
79
 
    [<a href="get-properties.jsp">Java Properties</a>]
80
 
    [<a href="threaddump.jsp">Thread Dump</a>]
81
 
  <%
82
 
    if (enabledFile!=null)
83
 
    if (isEnabled) {
84
 
  %>
85
 
  [<a href="action.jsp?action=Disable">Disable</a>]
86
 
  <%
87
 
    } else {
88
 
  %>
89
 
  [<a href="action.jsp?action=Enable">Enable</a>]
90
 
  <%
91
 
    }
92
 
  %>
93
 
  </td>
94
 
</tr>
95
 
 
96
 
 
97
 
<%
98
 
 // a quick hack to get rid of get-file.jsp -- note this still spits out invalid HTML
99
 
 out.write( org.apache.solr.handler.admin.ShowFileRequestHandler.getFileContents( "admin-extra.html" ) );
100
 
%>
101
 
 
102
 
</table><P>
103
 
 
104
 
 
105
 
<table>
106
 
<tr>
107
 
  <td>
108
 
        <h3>Make a Query</h3>
109
 
  </td>
110
 
  <td>
111
 
[<a href="form.jsp">Full Interface</a>]
112
 
  </td>
113
 
  
114
 
</tr>
115
 
<tr>
116
 
  <td>
117
 
  Query String:
118
 
  </td>
119
 
  <td colspan=2>
120
 
        <form name=queryForm method="GET" action="../select/" accept-charset="UTF-8">
121
 
        <textarea class="std" rows="4" cols="40" name="q"><%= defaultSearch %></textarea>
122
 
        <input name="version" type="hidden" value="2.2">
123
 
        <input name="start" type="hidden" value="0">
124
 
        <input name="rows" type="hidden" value="10">
125
 
        <input name="indent" type="hidden" value="on">
126
 
        <br><input class="stdbutton" type="submit" value="search" 
127
 
                onclick="if (queryForm.q.value.length==0) { alert('no empty queries, please'); return false; } else { queryForm.submit(); return false;} ">
128
 
        </form>
129
 
  </td>
130
 
</tr>
131
 
</table><p>
132
 
 
133
 
<table>
134
 
<tr>
135
 
  <td>
136
 
        <h3>Assistance</h3>
137
 
  </td>
138
 
  <td>
139
 
        [<a href="http://lucene.apache.org/solr/">Documentation</a>]
140
 
        [<a href="http://issues.apache.org/jira/browse/SOLR">Issue Tracker</a>]
141
 
        [<a href="mailto:solr-user@lucene.apache.org">Send Email</a>]
142
 
        <br>
143
 
        [<a href="http://wiki.apache.org/solr/SolrQuerySyntax">Solr Query Syntax</a>]
144
 
  </td>
145
 
</tr>
146
 
<tr>
147
 
  <td>
148
 
  </td>
149
 
  <td>
150
 
  Current Time: <%= new Date() %>
151
 
  </td>
152
 
</tr>
153
 
<tr>
154
 
  <td>
155
 
  </td>
156
 
  <td>
157
 
  Server Start At: <%= new Date(core.getStartTime()) %>
158
 
  </td>
159
 
</tr>
160
 
</table>
161
 
</body>
162
 
</html>