Software /
code /
prosody
Changeset
5660:df077bc8f019
mod_bosh: Make waiting_requests and dead_sessions shared to preserve across reloads
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sat, 08 Jun 2013 18:08:18 +0100 |
parents | 5659:9f9de8078164 |
children | 5661:f226a0d23e85 |
files | plugins/mod_bosh.lua |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_bosh.lua Sat Jun 08 18:07:36 2013 +0100 +++ b/plugins/mod_bosh.lua Sat Jun 08 18:08:18 2013 +0100 @@ -62,7 +62,7 @@ local sessions, inactive_sessions = module:shared("sessions", "inactive_sessions"); -- Used to respond to idle sessions (those with waiting requests) -local waiting_requests = {}; +local waiting_requests = module:shared("waiting_requests"); function on_destroy_request(request) log("debug", "Request destroyed: %s", tostring(request)); waiting_requests[request] = nil; @@ -397,7 +397,7 @@ end end -local dead_sessions = {}; +local dead_sessions = module:shared("dead_sessions"); function on_timer() -- log("debug", "Checking for requests soon to timeout..."); -- Identify requests timing out within the next few seconds