notifications: add more logging

needed this to debug stuff

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2024-09-05 16:53:38 -07:00
committed by Daniel D’Aquino
parent 1dbf7101b9
commit cb241741e3
3 changed files with 13 additions and 4 deletions

View File

@@ -111,8 +111,10 @@ class Ndb {
var ok = false
while !ok && mapsize > 1024 * 1024 * 700 {
var cfg = ndb_config(flags: 0, ingester_threads: ingest_threads, mapsize: mapsize, filter_context: nil, ingest_filter: nil)
ok = ndb_init(&ndb_p, testdir, &cfg) != 0
let res = ndb_init(&ndb_p, testdir, &cfg)
ok = res != 0;
if !ok {
Log.error("ndb_init failed: %d, reducing mapsize from %d to %d", for: .storage, res, mapsize, mapsize / 2)
mapsize /= 2
}
}