--- a/mod_inotify_reload/mod_inotify_reload.lua Mon Jul 16 22:30:43 2012 +0200
+++ b/mod_inotify_reload/mod_inotify_reload.lua Thu Jul 19 15:32:02 2012 +0100
@@ -44,16 +44,19 @@
local k = host.."\0"..name;
watches[k] = { id = id, path = path, name = name, host = host };
watch_ids[id] = k;
+ module:log("debug", "Watching %s:%s with id %d", name, host, id);
return true;
end
function unwatch_module(name, host)
local k = host.."\0"..name;
if not watches[k] then
+ module:log("warn", "Not watching %s:%s", name, host);
return nil, "not-watching";
end
local id = watches[k].id;
local ok, err = inh:rmwatch(id);
+ module:log("info", "Removed watch %d", id);
watches[k] = nil;
watch_ids[id] = nil;
return ok, err;