significantly faster sync with transactions

This commit is contained in:
zadam
2020-04-04 21:49:57 +02:00
parent ae50c9847d
commit b1bed18331
4 changed files with 31 additions and 28 deletions

View File

@@ -18,6 +18,9 @@ async function createConnection() {
const dbConnection = new Promise(async (resolve, reject) => {
// no need to create new connection now since DB stays the same all the time
const db = await createConnection();
db.run('PRAGMA journal_mode = WAL;');
sql.setDbConnection(db);
resolve();