Skip to content

Commit

Permalink
Setup vc-cache in the data folder (#598)
Browse files Browse the repository at this point in the history
Change-Id: I6a4c1177c4c4b052fff6df9076fcb34c0001cd58
  • Loading branch information
margaretha committed Apr 11, 2024
1 parent 05818b4 commit 0b110ed
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<jetty.version>11.0.19</jetty.version>
<flyway.version>10.6.0</flyway.version>
<log4j.version>2.22.1</log4j.version>
<krill.version>[0.62.2,)</krill.version>
<krill.version>[0.62.3,)</krill.version>
<koral.version>[0.42,)</koral.version>
</properties>
<profiles>
Expand Down
6 changes: 6 additions & 0 deletions src/main/java/de/ids_mannheim/korap/init/Initializator.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
import org.springframework.beans.factory.annotation.Autowired;

import de.ids_mannheim.korap.annotation.FreeResourceParser;
import de.ids_mannheim.korap.cache.VirtualCorpusCache;
import de.ids_mannheim.korap.config.FullConfiguration;
import de.ids_mannheim.korap.config.KustvaktConfiguration;
import de.ids_mannheim.korap.config.NamedVCLoader;
import de.ids_mannheim.korap.constant.OAuth2Scope;
import de.ids_mannheim.korap.exceptions.KustvaktException;
Expand Down Expand Up @@ -37,6 +39,8 @@ public class Initializator {
public Initializator () {}

public void init () throws IOException, QueryException, KustvaktException {
VirtualCorpusCache.CACHE_LOCATION = KustvaktConfiguration.DATA_FOLDER
+ "/vc-cache";
setInitialAccessScope();
resourceParser.run();

Expand All @@ -50,6 +54,8 @@ public void init () throws IOException, QueryException, KustvaktException {
}

public void initTest () throws IOException, KustvaktException {
VirtualCorpusCache.CACHE_LOCATION = KustvaktConfiguration.DATA_FOLDER
+ "/vc-cache";
setInitialAccessScope();
if (config.createInitialSuperClient()) {
clientService.createInitialTestSuperClient();
Expand Down

0 comments on commit 0b110ed

Please sign in to comment.