Integrate #346 for sqlite performance enhancement

* Update database journal mode to WAL as per
https://www.sqlite.org/wal.html
This commit is contained in:
abraunegg 2018-05-03 16:38:40 +10:00
parent 0b5dc66507
commit 4e0c3a4cf0

View file

@ -71,6 +71,8 @@ final class ItemDatabase
}
db.exec("PRAGMA foreign_keys = ON");
db.exec("PRAGMA recursive_triggers = ON");
db.exec("PRAGMA journal_mode = WAL");
insertItemStmt = db.prepare("
INSERT OR REPLACE INTO item (driveId, id, name, type, eTag, cTag, mtime, parentId, crc32Hash, sha1Hash, quickXorHash, remoteDriveId, remoteId)
VALUES (?1, ?2, ?3, ?4, ?5, ?6, ?7, ?8, ?9, ?10, ?11, ?12, ?13)