5 Star 1 Fork 0

Gitee 极速下载/Jabberd2

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/jabberd2/jabberd2
克隆/下载
TODO 2.65 KB
一键复制 编辑 原始数据 按行查看 历史
Tomasz Sterna 提交于 2006-04-16 20:42 . jabberstudio CVS import
TODO for 2.0
------------
Roster templates may not be working properly (esp. with multiple items).
Check and fix if necessary.
Make sure that available presence in response to a s10n accept arrives
after the type='subscribed' (see chat with Nathan Walp)
c2s may not be properly detecting client connections dropping. I feel
like I've checked this numerous times, so check once more, once and for
all.
Modify user-load chain calls to indicate if the user is being loaded for
a session, or just for delivery. Don't load rosters (and other large
things) in that case.
==========
The requirement for this is that large presence broadcasts (for the
same host) result in many users being loaded for delivery, only to
find out that they have no sessions online, and then being unloaded
again. If we could stop some parts of the user data being loaded when
the user is loaded only for packet delivery, then the overhead could
be kept to a minimum.
Privacy lists make this hard, if not impossible. Privacy lists must be
loaded at packet delivery time, because the user may have a default
list. That default list may have rules based on roster group, so the
roster must be loaded.
A partial solution might be to have a module that runs in in-router
before mod_privacy, that watches for presence packets and drops them
if the user is not online. This should work, because even if the
presence packet was allowed by the default privacy list, it'll get
dropped anyway because mod_deliver would find later that there are no
sessions online.
This doesn't fix the problem completely though because mod_privacy
needs the user's roster loaded in order to process a default list with
rules based on roster group. There's no way for mod_privacy to call
into mod_roster to get it to load the roster on demand.
Long term, there's a couple of possibilities. In general, I believe
its reasonable to either have all user data loaded, or none of it -
anything in between requires a measure of the "importance" of certain
data (which doesn't scale and is highly subjective) or a on-demand
system of loading data, which requires dependency graphs and
inter-module communication. This stuff isn't impossible, but I don't
want to go there if I can help it.
It might be better to simply implement a (configurable) delay before
unused user data is unloaded. This will still mean that the first
presence broadcast can get sluggish, but after this things should chug
along nicely.
A patch for the partial soltuion mentioned above has been implemented,
as _presence_in_router(). This is not a complete fix, but does
workaround the most common case.
==========
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C
1
https://gitee.com/mirrors/jabberd2.git
git@gitee.com:mirrors/jabberd2.git
mirrors
jabberd2
Jabberd2
master

搜索帮助

23e8dbc6 1850385 7e0993f3 1850385