annotate mod_muc_slow_mode/README.markdown @ 5963:c61a82f80e57 default tip

mod_pubsub_serverinfo: Reference workaround for issue #1841
author Guus der Kinderen <guus.der.kinderen@gmail.com>
date Wed, 11 Sep 2024 14:02:39 +0200
parents 22effe87fed2
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5939
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
1 <!--
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
2 SPDX-FileCopyrightText: 2024 John Livingston <https://www.john-livingston.fr/>
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
3 SPDX-License-Identifier: AGPL-3.0-only
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
4 -->
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
5 # mod_muc_slow_mode
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
6
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
7 This module is a custom module that allows slow mode for MUC rooms.
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
8
5940
83787415fc8d mod_muc_slow_mode: update readme file.
John Livingston <git@john-livingston.fr>
parents: 5939
diff changeset
9 This module is under AGPL-3.0 license.
5939
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
10
5947
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
11 There will probably be a XEP proposal for this module behaviour.
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
12
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
13 ## Slow mode definition
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
14
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
15 There are some contexts in which you want to be able to rate limit MUC messages. This could have multiple motivations: avoid flooding, garantee a better readability of the room when there are hundreds of active users, …
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
16
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
17 This module propose a new option for MUC rooms, allowing room owners to fix a duration that users must wait between two messages.
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
18
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
19 There is a draft XEP for this feature, that you can find here: https://github.com/JohnXLivingston/xeps/blob/xep-slow-mode/xep-slow-mode.xml
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
20
22effe87fed2 mod_muc_slow_mode: adding more context in the README.
John Livingston <git@john-livingston.fr>
parents: 5940
diff changeset
21 There is a more human-readable version of this XEP here: https://livingston.frama.io/peertube-plugin-livechat/technical/slow_mode/
5939
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
22
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
23 ## Configuration
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
24
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
25 Just enable the module on your MUC component.
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
26 The feature will be accessible throught the room configuration form.
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
27
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
28 Depending on your application, it is possible that the slow mode is more important than other fields (for example for a video streaming service).
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
29 The position in the room config form can be changed be setting the option `slow_mode_duration_form_position`.
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
30 This value will be passed as priority for the "muc-config-form" hook.
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
31 By default, the field will be between muc#roomconfig_changesubject and muc#roomconfig_moderatedroom.
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
32
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
33 ``` lua
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
34 VirtualHost "muc.example.com"
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
35 modules_enabled = { "muc_slow_mode" }
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
36 slow_mode_duration_form_position = 96
d7c207964aa5 mod_muc_slow_mode: initial commit.
John Livingston <git@john-livingston.fr>
parents:
diff changeset
37 ```