diff options
-rw-r--r-- | lib/PublicInbox/Msgmap.pm | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/PublicInbox/Msgmap.pm b/lib/PublicInbox/Msgmap.pm index 9523752e..5fe14383 100644 --- a/lib/PublicInbox/Msgmap.pm +++ b/lib/PublicInbox/Msgmap.pm @@ -48,6 +48,10 @@ sub new_file { if ($writable) { create_tables($dbh); + + # TRUNCATE reduces I/O compared to the default (DELETE) + $dbh->do('PRAGMA journal_mode = TRUNCATE'); + $dbh->begin_work; $self->created_at(time) unless $self->created_at; |