truncate WAL log on start
parent
cec3c4891e
commit
dacfc57d11
|
@ -278,8 +278,8 @@ pub fn open_upend<P: AsRef<Path>>(
|
||||||
|
|
||||||
let enable_wal_mode = true;
|
let enable_wal_mode = true;
|
||||||
pool.get().unwrap().execute(if enable_wal_mode {
|
pool.get().unwrap().execute(if enable_wal_mode {
|
||||||
trace!("Enabling WAL journal mode");
|
trace!("Enabling WAL journal mode & truncating WAL log...");
|
||||||
"PRAGMA journal_mode = WAL;"
|
"PRAGMA journal_mode = WAL;PRAGMA wal_checkpoint(TRUNCATE);"
|
||||||
} else {
|
} else {
|
||||||
trace!("Enabling TRUNCATE journal mode");
|
trace!("Enabling TRUNCATE journal mode");
|
||||||
"PRAGMA journal_mode = TRUNCATE;"
|
"PRAGMA journal_mode = TRUNCATE;"
|
||||||
|
|
Loading…
Reference in New Issue