diff options
author | Andrew Lewis <nerf@judo.za.org> | 2016-11-21 19:27:19 +0200 |
---|---|---|
committer | Andrew Lewis <nerf@judo.za.org> | 2016-11-21 19:27:19 +0200 |
commit | 91a96742d37ca1b096b825f7a941b42aa4987e51 (patch) | |
tree | a8fed38382c3523a99ec97ed41645adf6a51aca5 | |
parent | 919cbd477d499804b17c87656a435db6067ca31e (diff) | |
download | rspamd-91a96742d37ca1b096b825f7a941b42aa4987e51.tar.gz rspamd-91a96742d37ca1b096b825f7a941b42aa4987e51.zip |
[Minor] Improve replies module logging
-rw-r--r-- | src/plugins/lua/replies.lua | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/plugins/lua/replies.lua b/src/plugins/lua/replies.lua index b5c7c6ada..6704882e0 100644 --- a/src/plugins/lua/replies.lua +++ b/src/plugins/lua/replies.lua @@ -41,7 +41,7 @@ end local function replies_check(task) local function redis_get_cb(err, data) if err ~= nil then - rspamd_logger.errx('redis_get_cb received error: %1', err) + rspamd_logger.errx(task, 'redis_get_cb received error: %1', err) return end if data == '1' then @@ -75,14 +75,14 @@ local function replies_check(task) ) if not ret then - rspamd_logger.errx("redis request wasn't scheduled") + rspamd_logger.errx(task, "redis request wasn't scheduled") end end local function replies_set(task) local function redis_set_cb(err) if err ~=nil then - rspamd_logger.errx('redis_set_cb received error: %1', err) + rspamd_logger.errx(task, 'redis_set_cb received error: %1', err) end end -- If sender is unauthenticated return @@ -97,6 +97,7 @@ local function replies_set(task) end -- Create hash of message-id and store to redis local key = make_key(msg_id) + rspamd_logger.infox(task, 'storing message-id for replies check') local ret = rspamd_redis_make_request(task, redis_params, -- connect params key, -- hash key @@ -106,7 +107,7 @@ local function replies_set(task) {key, tostring(settings['expire']), "1"} -- arguments ) if not ret then - rspamd_logger.errx("redis request wasn't scheduled") + rspamd_logger.errx(task, "redis request wasn't scheduled") end end |