|
1 --- |
|
2 labels: |
|
3 - 'Stage-Beta' |
|
4 summary: 'XEP-0198: Reliability and fast reconnects for XMPP' |
|
5 ... |
|
6 |
|
7 Introduction |
|
8 ============ |
|
9 |
|
10 By default XMPP is as reliable as your network is. Unfortunately in some |
|
11 cases that is not very reliable - in some network conditions disconnects |
|
12 can be frequent and message loss can occur. |
|
13 |
|
14 To overcome this, XMPP has an optional extension (XEP-0198: Stream |
|
15 Management) which, when supported by both the client and server, can |
|
16 allow a client to resume a disconnected session, and prevent message |
|
17 loss. |
|
18 |
|
19 Details |
|
20 ======= |
|
21 |
|
22 When using XEP-0198 both the client and the server keep a queue of the |
|
23 most recently sent stanzas - this is cleared when the other end |
|
24 acknowledges they have received the stanzas. If the client disconnects, |
|
25 instead of marking the user offline the server pretends the client is |
|
26 still online for a short (configurable) period of time. If the client |
|
27 reconnects within this period, any stanzas in the queue that the client |
|
28 did not receive are re-sent. |
|
29 |
|
30 If the client fails to reconnect before the timeout then it is marked |
|
31 offline as normal, and any stanzas in the queue are returned to the |
|
32 sender as a "recipient-unavailable" error. |
|
33 |
|
34 Configuration |
|
35 ============= |
|
36 |
|
37 Option Default Description |
|
38 --------------------------- ----------------- ----------------------------------------------------------------------------------------- |
|
39 smacks\_hibernation\_time 300 (5 minutes) The number of seconds a disconnected session should stay alive for (to allow reconnect) |
|
40 |
|
41 Compatibility |
|
42 ============= |
|
43 |
|
44 ----- -------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
45 0.9 Works |
|
46 0.8 Works, use version [7693724881b3](http://prosody-modules.googlecode.com/hg-history/7693724881b3f3cdafa35763f00dd040d02313bf/mod_smacks/mod_smacks.lua) |
|
47 ----- -------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
48 |
|
49 Clients |
|
50 ======= |
|
51 |
|
52 Clients that support XEP-0198: |
|
53 |
|
54 - Gajim |
|
55 - Swift (but not resumption, as of version 2.0 and alphas of 3.0) |
|
56 - Psi (in an unreleased branch) |
|
57 - Yaxim |