Software /
code /
prosody-modules
Comparison
mod_log_slow_events/mod_log_slow_events.lua @ 1695:78b3b3add19c
mod_log_slow_events: Minor improvement to log message
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Tue, 05 May 2015 14:20:53 +0100 |
parent | 1680:a9df1f7e273d |
child | 1696:efc1d674eac0 |
comparison
equal
deleted
inserted
replaced
1694:25412e94fb3e | 1695:78b3b3add19c |
---|---|
27 local stanza = event_data.stanza; | 27 local stanza = event_data.stanza; |
28 if stanza then | 28 if stanza then |
29 log_data("stanza", tostring(stanza)); | 29 log_data("stanza", tostring(stanza)); |
30 end | 30 end |
31 end | 31 end |
32 module:log("warn", "Slow event '%s' took %0.2f: %s", event_name, duration, next(data) and table.concat(data, ", ") or "no recognised data"); | 32 module:log("warn", "Slow event '%s' took %0.2fs: %s", event_name, duration, next(data) and table.concat(data, ", ") or "no recognised data"); |
33 end | 33 end |
34 return ret; | 34 return ret; |
35 end); | 35 end); |