Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Huge rdbms load when using mod_privacy #4371

Open
oybek opened this issue Sep 6, 2024 · 1 comment
Open

Huge rdbms load when using mod_privacy #4371

oybek opened this issue Sep 6, 2024 · 1 comment

Comments

@oybek
Copy link

oybek commented Sep 6, 2024

MongooseIM version: 6.2
Installed from: source
Erlang/OTP version: 26

If we use

[modules.mod_privacy]
    backend = "rdbms"

for each send stanza, mongooseim goes into rdbms to fetch privacy list causing a huge load into rdbms

@arcusfelis
Copy link
Contributor

Hi,
@oybek It is a bit by design. We need to do privacy check, in the current XEPs.

ejabberd actually does not do privacy check for offline users, just writes messages in mod_offline and when a user returns, they read offline storage, read privacy list once and archive privacy-passed messages. So, here you do not need to run a privacy check, profit! Except if you use push notifications, you still have to. Or if you read archive though HTTP interface, without XMPP login...

You can write a module to cache privacy list in redis though, it likes that type of load.
I also don't like current way of MAM working, we should just allow a user to send message to a conversation in archive, but not notify receiver, if he blocks the sender... Like many other messages do... So, we need a mute checker (oh, and we still need to do the check, before potentially pushing messages though push notifications).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants