Skip to content

Commit 295ea21

Browse files
committed
feat(model-server): new cmdline parameter --local-persistence
Uses ignite with local storage, without having to run a postgres database. The map based in memory storage often behaves differently and doesn't show the same performance issues as the ignite implementation. This new option allows more realistic testing.
1 parent 4536ef0 commit 295ea21

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

model-server/src/main/kotlin/org/modelix/model/server/CmdLineArgs.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ internal class CmdLineArgs {
2121
@Parameter(names = ["-inmemory"], description = "Use in-memory storage", converter = BooleanConverter::class)
2222
var inmemory = false
2323

24+
@Parameter(names = ["--local-persistence"], description = "Use ignite with local disk persistence", converter = BooleanConverter::class)
25+
var localPersistence = false
26+
2427
@Parameter(names = ["-dumpout"], description = "Dump in memory storage", converter = StringConverter::class)
2528
var dumpOutName: String? = null
2629

model-server/src/main/kotlin/org/modelix/model/server/Main.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,8 @@ object Main {
130130
),
131131
)
132132
}
133+
} else if (cmdLineArgs.localPersistence) {
134+
storeClient = IgniteStoreClient(cmdLineArgs.jdbcConfFile, inmemory = true)
133135
} else {
134136
storeClient = IgniteStoreClient(cmdLineArgs.jdbcConfFile)
135137
if (cmdLineArgs.schemaInit) {

0 commit comments

Comments
 (0)