--- a/mod_presence_cache/README.markdown Fri Apr 01 15:11:25 2016 +0200
+++ b/mod_presence_cache/README.markdown Fri Apr 01 15:15:56 2016 +0200
@@ -13,10 +13,6 @@
client is doubled, as the client would get both the cached stanzas and
replies to presence probes. Also see [mod\_throttle\_presence].
-By default, only binary (online or offline) state is stored. It can
-optionally store the full presence but this requires much more memory
-and bandwidth.
-
Configuration
=============
@@ -30,12 +26,8 @@
Advanced configuration
======================
-To enable *experimental* full stanza caching:
- presence_cache_full = false
-This will usually double the presence data sent to clients, pending
-support for deduplication.
TODO
====
--- a/mod_presence_cache/mod_presence_cache.lua Fri Apr 01 15:11:25 2016 +0200
+++ b/mod_presence_cache/mod_presence_cache.lua Fri Apr 01 15:15:56 2016 +0200
@@ -6,8 +6,6 @@
local presence_cache = {}; -- Reload to empty
-local cache_full = module:get_option_boolean(module.name.."_full", false);
-
local function cache_hook(event)
local origin, stanza = event.origin, event.stanza;
local typ = stanza.attr.type;
@@ -42,10 +40,6 @@
presence_cache[username] = nil;
end
end
- elseif cache_full then
- stanza = st.clone(stanza);
- stanza:tag("delay", { xmlns = "urn:xmpp:delay", from = module.host, stamp = datetime.datetime() }):up();
- contact_presence_cache[from_jid] = stanza;
else -- only cache binary state
contact_presence_cache[from_jid] = datetime.datetime();
end
@@ -77,9 +71,6 @@
end
origin.send(presence);
end
- if cache_full then
- return true;
- end
end
module:hook("pre-presence/bare", answer_probe_from_cache, 10);