From 05a6415ec0fdf0799dedae774a5cc9f758f83585 Mon Sep 17 00:00:00 2001 From: Dmitry Bushev Date: Wed, 7 Sep 2022 12:59:18 +0300 Subject: [PATCH] create inmem database (#3690) --- .../scala/org/enso/languageserver/boot/MainModule.scala | 9 +-------- .../src/main/scala/org/enso/searcher/sql/Tables.scala | 2 +- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/engine/language-server/src/main/scala/org/enso/languageserver/boot/MainModule.scala b/engine/language-server/src/main/scala/org/enso/languageserver/boot/MainModule.scala index d3bf174dd17..09592c20c74 100644 --- a/engine/language-server/src/main/scala/org/enso/languageserver/boot/MainModule.scala +++ b/engine/language-server/src/main/scala/org/enso/languageserver/boot/MainModule.scala @@ -9,7 +9,6 @@ import org.enso.distribution.{DistributionManager, Environment, LanguageHome} import org.enso.editions.EditionResolver import org.enso.editions.updater.EditionManager import org.enso.jsonrpc.JsonRpcServer -import org.enso.languageserver.boot.DeploymentType.{Azure, Desktop} import org.enso.languageserver.capability.CapabilityRouter import org.enso.languageserver.data._ import org.enso.languageserver.effect @@ -109,13 +108,7 @@ class MainModule(serverConfig: LanguageServerConfig, logLevel: LogLevel) { Sha3_224VersionCalculator log.trace("Created Version Calculator [{}].", versionCalculator) - val sqlDatabase = - DeploymentType.fromEnvironment() match { - case Desktop => - SqlDatabase(languageServerConfig.directories.suggestionsDatabaseFile) - case Azure => - SqlDatabase.inmem("memdb") - } + val sqlDatabase = SqlDatabase.inmem("memdb") val suggestionsRepo = new SqlSuggestionsRepo(sqlDatabase)(system.dispatcher) val versionsRepo = new SqlVersionsRepo(sqlDatabase)(system.dispatcher) diff --git a/lib/scala/searcher/src/main/scala/org/enso/searcher/sql/Tables.scala b/lib/scala/searcher/src/main/scala/org/enso/searcher/sql/Tables.scala index 58372ba0853..4d6a9666a2b 100644 --- a/lib/scala/searcher/src/main/scala/org/enso/searcher/sql/Tables.scala +++ b/lib/scala/searcher/src/main/scala/org/enso/searcher/sql/Tables.scala @@ -263,5 +263,5 @@ object SuggestionsVersion extends TableQuery(new SuggestionsVersionTable(_)) object SchemaVersion extends TableQuery(new SchemaVersionTable(_)) { /** The current schema version. */ - val CurrentVersion: Long = 6 + val CurrentVersion: Long = 7 }