comparison mod_s2s_cache_failures/README.md @ 6343:ee2ebdec1fae

mod_s2s_cache_failures: New module to cache failures to remote domains and control retries
author Matthew Wild <mwild1@gmail.com>
date Thu, 16 Oct 2025 19:08:20 +0100
parents
children
comparison
equal deleted inserted replaced
6342:4c98f4340bf1 6343:ee2ebdec1fae
1 ---
2 labels:
3 - Statistics
4 - Stage-Alpha
5 summary: Cache s2s failures and prevent excessive retries
6 ...
7
8 ## Description
9
10 This module essentially rate limits the number of outgoing connection attempts
11 to domains that Prosody hasn't been able to connect to.
12
13 This can help with resource usage (no need to queue undelivered stanzas for
14 unreachable domains), and also reduces noise in the log files.
15
16 The retry period is proportional to the amount of time since Prosody last had
17 a connection to the domain. It also includes some randomness to prevent
18 multiple servers unintentially flooding a domain with reconnection attempts at
19 the same time. On average a failed domain will be tried around 15 times in the
20 first hour of unavailability, decreasing in frequency to 1-2 attempts per hour
21 after that.
22
23 ## Configuration
24
25 The only configuration option is:
26
27 `s2s_failure_cache_size`
28 : The number of failed domains that will be remembered (overflows will simply
29 cause failures to be forgotten, and Prosody will retry those domains).
30
31 ## Compatibility
32
33 Requires Prosody 13.0 or later.
34
35 For users of Prosody trunk after 13.0, commit [4067a95336dd](https://hg.prosody.im/trunk/rev/4067a95336dd)
36 introduces a new `s2s_block_immediate_retries` option which you may want to
37 enable, to catch some cases of retries which this module cannot otherwise
38 prevent.