ndb: add nostrdb migrations

This commit is contained in:
William Casarin
2023-09-13 05:40:44 -07:00
parent 69c7acea76
commit fafe3b4b3e
3 changed files with 164 additions and 6 deletions

View File

@@ -33,7 +33,7 @@ class Ndb {
let ok = path.withCString { testdir in
var ok = false
while !ok && mapsize > 1024 * 1024 * 700 {
ok = ndb_init(&ndb_p, testdir, mapsize, ingest_threads) != 0
ok = ndb_init(&ndb_p, testdir, mapsize, ingest_threads, 0) != 0
if !ok {
mapsize /= 2
}