Refactor DatabaseManager to initialize ChromaSync lazily and remove background backfill on startup

This commit is contained in:
Alex Newman
2025-12-27 22:00:49 -05:00
parent 949b845992
commit ab2db783bc
2 changed files with 2 additions and 7 deletions
+1 -6
View File
@@ -27,14 +27,9 @@ export class DatabaseManager {
this.sessionStore = new SessionStore();
this.sessionSearch = new SessionSearch();
// Initialize ChromaSync
// Initialize ChromaSync (lazy - connects on first search, not at startup)
this.chromaSync = new ChromaSync('claude-mem');
// Start background backfill (fire-and-forget)
this.chromaSync.ensureBackfilled().catch(error => {
logger.error('DB', 'Chroma backfill failed (non-fatal)', {}, error);
});
logger.info('DB', 'Database initialized');
}