VIVO-511 allowing only 1 complete migration
This commit is contained in:
parent
5d19e746e1
commit
fc90df70f3
2 changed files with 4 additions and 2 deletions
|
@ -346,7 +346,9 @@ public class KnowledgeBaseUpdater {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isUpdatableABoxGraph(String graphName) {
|
public static boolean isUpdatableABoxGraph(String graphName) {
|
||||||
return (!graphName.contains("tbox") && !graphName.contains("filegraph"));
|
return (graphName != null && !graphName.contains("tbox")
|
||||||
|
&& !graphName.contains("filegraph")
|
||||||
|
&& !graphName.contains("x-arq:UnionGraph"));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -141,7 +141,7 @@ public class UpdateKnowledgeBase implements ServletContextListener {
|
||||||
KnowledgeBaseUpdater ontologyUpdater = new KnowledgeBaseUpdater(settings);
|
KnowledgeBaseUpdater ontologyUpdater = new KnowledgeBaseUpdater(settings);
|
||||||
boolean requiredUpdate = ontologyUpdater.updateRequired(ctx);
|
boolean requiredUpdate = ontologyUpdater.updateRequired(ctx);
|
||||||
|
|
||||||
if(!JenaDataSourceSetupBase.isFirstStartup()) {
|
if(requiredUpdate && !JenaDataSourceSetupBase.isFirstStartup()) {
|
||||||
try {
|
try {
|
||||||
ctx.setAttribute(KBM_REQURIED_AT_STARTUP, Boolean.TRUE);
|
ctx.setAttribute(KBM_REQURIED_AT_STARTUP, Boolean.TRUE);
|
||||||
migrationChangesMade = ontologyUpdater.update(ctx);
|
migrationChangesMade = ontologyUpdater.update(ctx);
|
||||||
|
|
Loading…
Add table
Reference in a new issue