Smack/smack-tcp/src/main/java/org/jivesoftware/smack
Georg Lukas e5bbd19ef1 StanzaDroppedListener for XEP-0198 resumption failures
If a stream resume fails, smack will re-send all queued stanzas after a
reconnect. However, it does not make sense to re-send them:

* IQs / IQ responses have probably timed out
* MUC messages and PMs will be rejected as you haven't rejoined yet
* regular messages should be amended with a <delay> element

This patch adds a StanzaDroppedListener interface to the
XMPPTCPConnection. If at least one StanzaDroppedListener is provided,
all queued messages will be drained into the StanzaDroppedListener(s).
Otherwise, the original behavior of attempting to transmit them will be
followed.

Discussion: https://discourse.igniterealtime.org/t/xep-0198-resume-failure-reconnect-resending-of-muc-messages/83510/3

Signed-off-by: Georg Lukas <georg@op-co.de>
2019-03-10 21:24:37 +01:00
..
sm Check if unacknowledged stanzas queue is full before adding to it 2018-12-08 22:54:13 +01:00
tcp StanzaDroppedListener for XEP-0198 resumption failures 2019-03-10 21:24:37 +01:00