diff options
author | Kim Alvefur <zash@zash.se> | 2015-09-25 15:16:25 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2015-09-25 15:16:25 +0200 |
commit | d71ec76461ec8afd64a2115066a0898c3cbe8ece (patch) | |
tree | a3264f297c742b9d46c02ae65199ecb057c8964d /plugins/mod_s2s/mod_s2s.lua | |
parent | 7dda2051767b494cba55b3b8c3a3086b60252f9a (diff) | |
download | prosody-d71ec76461ec8afd64a2115066a0898c3cbe8ece.tar.gz prosody-d71ec76461ec8afd64a2115066a0898c3cbe8ece.zip |
mod_s2s: Account for connections that time out in connection count measure
Diffstat (limited to 'plugins/mod_s2s/mod_s2s.lua')
-rw-r--r-- | plugins/mod_s2s/mod_s2s.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/mod_s2s/mod_s2s.lua b/plugins/mod_s2s/mod_s2s.lua index b44000a6..1ecb75da 100644 --- a/plugins/mod_s2s/mod_s2s.lua +++ b/plugins/mod_s2s/mod_s2s.lua @@ -611,6 +611,11 @@ function listener.onstatus(conn, status) end end +function listener.ontimeout(conn) + -- Called instead of onconnect when the connection times out + measure_connections(1); +end + function listener.ondisconnect(conn, err) measure_connections(-1); local session = sessions[conn]; |