Changeset

1756:c619425dafe7

mod_storage_gdbm: Reorganize (vacuum) databases on module unload
author Kim Alvefur <zash@zash.se>
date Tue, 19 May 2015 23:30:39 +0200
parents 1755:0a21b16b9075
children 1757:d011b87b7f58
files mod_storage_gdbm/mod_storage_gdbm.lua
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mod_storage_gdbm/mod_storage_gdbm.lua	Tue May 19 23:29:37 2015 +0200
+++ b/mod_storage_gdbm/mod_storage_gdbm.lua	Tue May 19 23:30:39 2015 +0200
@@ -170,6 +170,7 @@
 function module.unload()
 	for db_path, db in pairs(cache) do
 		module:log("debug", "Closing db at %q", db_path);
+		gdbm.reorganize(db);
 		gdbm.sync(db);
 		gdbm.close(db);
 	end