VIVO-719 Improve the user interface
This commit is contained in:
parent
be11b190bc
commit
ae6a2a7251
5 changed files with 53 additions and 33 deletions
|
@ -204,7 +204,6 @@ public class BaseSiteAdminController extends FreemarkerHttpServlet {
|
||||||
urls.put("rdfData", UrlBuilder.getUrl("/uploadRDFForm"));
|
urls.put("rdfData", UrlBuilder.getUrl("/uploadRDFForm"));
|
||||||
urls.put("rdfExport", UrlBuilder.getUrl("/export"));
|
urls.put("rdfExport", UrlBuilder.getUrl("/export"));
|
||||||
urls.put("sparqlQueryBuilder", UrlBuilder.getUrl("/admin/sparqlquerybuilder"));
|
urls.put("sparqlQueryBuilder", UrlBuilder.getUrl("/admin/sparqlquerybuilder"));
|
||||||
urls.put("dumpRestore", UrlBuilder.getUrl("/dumpRestore"));
|
|
||||||
}
|
}
|
||||||
if (PolicyHelper.isAuthorizedForActions(vreq, SimplePermission.USE_SPARQL_QUERY_PAGE.ACTION)) {
|
if (PolicyHelper.isAuthorizedForActions(vreq, SimplePermission.USE_SPARQL_QUERY_PAGE.ACTION)) {
|
||||||
urls.put("sparqlQuery", UrlBuilder.getUrl("/admin/sparqlquery"));
|
urls.put("sparqlQuery", UrlBuilder.getUrl("/admin/sparqlquery"));
|
||||||
|
|
|
@ -65,6 +65,7 @@ import edu.cornell.mannlib.vitro.webapp.auth.permissions.SimplePermission;
|
||||||
import edu.cornell.mannlib.vitro.webapp.beans.Ontology;
|
import edu.cornell.mannlib.vitro.webapp.beans.Ontology;
|
||||||
import edu.cornell.mannlib.vitro.webapp.controller.Controllers;
|
import edu.cornell.mannlib.vitro.webapp.controller.Controllers;
|
||||||
import edu.cornell.mannlib.vitro.webapp.controller.VitroRequest;
|
import edu.cornell.mannlib.vitro.webapp.controller.VitroRequest;
|
||||||
|
import edu.cornell.mannlib.vitro.webapp.controller.freemarker.UrlBuilder;
|
||||||
import edu.cornell.mannlib.vitro.webapp.dao.ModelAccess;
|
import edu.cornell.mannlib.vitro.webapp.dao.ModelAccess;
|
||||||
import edu.cornell.mannlib.vitro.webapp.dao.ModelAccess.ModelID;
|
import edu.cornell.mannlib.vitro.webapp.dao.ModelAccess.ModelID;
|
||||||
import edu.cornell.mannlib.vitro.webapp.dao.ModelAccess.ModelMakerID;
|
import edu.cornell.mannlib.vitro.webapp.dao.ModelAccess.ModelMakerID;
|
||||||
|
@ -180,6 +181,9 @@ public class JenaIngestController extends BaseEditController {
|
||||||
} else if("mergeResult".equals(actionStr)){
|
} else if("mergeResult".equals(actionStr)){
|
||||||
processMergeResultRequest(vreq, response);
|
processMergeResultRequest(vreq, response);
|
||||||
return;
|
return;
|
||||||
|
} else if ("dumpRestore".equals(actionStr)) {
|
||||||
|
processDumpRestore(vreq, response);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
else {
|
else {
|
||||||
|
@ -1175,6 +1179,11 @@ public class JenaIngestController extends BaseEditController {
|
||||||
vreq.setAttribute("bodyJsp",LIST_MODELS_JSP);
|
vreq.setAttribute("bodyJsp",LIST_MODELS_JSP);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void processDumpRestore(VitroRequest vreq,
|
||||||
|
HttpServletResponse response) throws ServletException, IOException {
|
||||||
|
vreq.getRequestDispatcher("/dumpRestore").forward(vreq, response);
|
||||||
|
}
|
||||||
|
|
||||||
private class CollationSort implements Comparator<String> {
|
private class CollationSort implements Comparator<String> {
|
||||||
|
|
||||||
Collator collator;
|
Collator collator;
|
||||||
|
|
|
@ -31,3 +31,7 @@
|
||||||
<ul class="ingestMenu">
|
<ul class="ingestMenu">
|
||||||
<li><a href="ingest?action=executeWorkflow" title="Execute an RDF-encoded ingest workflow">Execute Workflow</a></li>
|
<li><a href="ingest?action=executeWorkflow" title="Execute an RDF-encoded ingest workflow">Execute Workflow</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<ul class="ingestMenu">
|
||||||
|
<li><a href="ingest?action=dumpRestore" title="Dump or Restore the knowledge base">Dump or Restore the knowledge base</a></li>
|
||||||
|
</ul>
|
||||||
|
|
|
@ -1,38 +1,38 @@
|
||||||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
||||||
|
|
||||||
<h2>Dump/Restore knowledge base</h2>
|
<style media="screen" type="text/css">
|
||||||
|
p.explain {
|
||||||
|
font-style: italic;
|
||||||
|
margin-left: 5em;
|
||||||
|
}
|
||||||
|
table.choices td {
|
||||||
|
padding-left: 2em;
|
||||||
|
padding-right: 2em;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
<h3>Before you start:</h3>
|
<h2>Dump or Restore the knowledge base</h2>
|
||||||
<ul>
|
|
||||||
<li>
|
<p class="explain">
|
||||||
<b>Content models</b> hold the data that VIVO contains and operates on.
|
<b>Content models</b> hold the data that VIVO contains and operates on.
|
||||||
This includes the ABox and the TBox, instances and ontologies, assertions and inferences.
|
This includes the ABox and the TBox, instances and ontologies, assertions and inferences.
|
||||||
</li>
|
</p>
|
||||||
<li>
|
<p class="explain">
|
||||||
<b>Configuration models</b> hold the data that controls VIVO,
|
<b>Configuration models</b> hold the data that controls VIVO,
|
||||||
including display options, privacy restrictions, and user accounts.
|
including display options, privacy restrictions, and user accounts.
|
||||||
</li>
|
</p>
|
||||||
<li>
|
|
||||||
Dumping the content models make take several minutes, and may produce large files.
|
|
||||||
For example, dumping a fully populated VIVO instance may take 20 minutes and produce a file of 3 gigabytes.
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
The restore process is additive: it will not delete existing triples.
|
|
||||||
However, duplicate triples will not be stored.
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
After restoring, the search index should be re-built.
|
|
||||||
The data will probably not require re-inferencing,
|
|
||||||
since the dump includes both assertions and inferences.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
<h3>Dump</h3>
|
<h3>Dump</h3>
|
||||||
|
|
||||||
|
<p class="explain">
|
||||||
|
Dumping the content models make take several minutes, and may produce large files.
|
||||||
|
For example, dumping a fully populated VIVO instance may take 20 minutes and produce a file of 3 gigabytes.
|
||||||
|
</p>
|
||||||
|
|
||||||
<form action="${selectUrl}" method="get">
|
<form action="${selectUrl}" method="get">
|
||||||
<table>
|
<table class="choices">
|
||||||
<tr>
|
<tr>
|
||||||
<td>Select models</td>
|
<td>Select models</td>
|
||||||
<td>Select format</td>
|
<td>Select format</td>
|
||||||
|
@ -63,6 +63,17 @@
|
||||||
|
|
||||||
<h3>Restore</h3>
|
<h3>Restore</h3>
|
||||||
|
|
||||||
|
<p class="explain">
|
||||||
|
The restore process is additive: it will not delete existing triples.
|
||||||
|
</p>
|
||||||
|
<p class="explain">
|
||||||
|
Choosing to purge large models can result in an OutOfMemory error.
|
||||||
|
It is better to start with a small or empty knowledge base.
|
||||||
|
</p>
|
||||||
|
<p class="explain">
|
||||||
|
After restoring, it is not necessary to rebuild the search index, or re-inference the data.
|
||||||
|
</p>
|
||||||
|
|
||||||
<#if tripleCount?? >
|
<#if tripleCount?? >
|
||||||
<section class="restore-feedback">
|
<section class="restore-feedback">
|
||||||
<p>Loaded ${tripleCount} triples</p>
|
<p>Loaded ${tripleCount} triples</p>
|
||||||
|
@ -70,7 +81,7 @@
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
<form action="${restoreUrl}" enctype="multipart/form-data" method="post">
|
<form action="${restoreUrl}" enctype="multipart/form-data" method="post">
|
||||||
<table>
|
<table class="choices">
|
||||||
<tr>
|
<tr>
|
||||||
<td>Select models</td>
|
<td>Select models</td>
|
||||||
<td>Select a file to restore from</td>
|
<td>Select a file to restore from</td>
|
||||||
|
|
|
@ -22,9 +22,6 @@
|
||||||
<#if dataTools.sparqlQueryBuilder?has_content>
|
<#if dataTools.sparqlQueryBuilder?has_content>
|
||||||
<li role="listitem"><a href="${dataTools.sparqlQueryBuilder}" title="${i18n().sparql_query_builder}">${i18n().sparql_query_builder}</a></li>
|
<li role="listitem"><a href="${dataTools.sparqlQueryBuilder}" title="${i18n().sparql_query_builder}">${i18n().sparql_query_builder}</a></li>
|
||||||
</#if>
|
</#if>
|
||||||
<#if dataTools.dumpRestore?has_content>
|
|
||||||
<li role="listitem"><a href="${dataTools.dumpRestore}" title="${i18n().dump_restore}">${i18n().dump_restore}</a></li>
|
|
||||||
</#if>
|
|
||||||
</ul>
|
</ul>
|
||||||
</section>
|
</section>
|
||||||
</#if>
|
</#if>
|
Loading…
Add table
Add a link
Reference in a new issue