xmppjs / xmpp.js

XMPP for JavaScript
ISC License
2.18k stars 371 forks source link

Implement stream management requesting ACKs #1005

Open singpolyma opened 7 months ago

singpolyma commented 7 months ago

Queue outgoing stanzas and periodically request ACK. Remove from the queue anything ack'd and notify of the ack so apps can know the stanza has for sure sent.

On resume, anything not ack'd is re-sent. On reconnect, anything not ack'd notify of the failure to send this stanza so apps can know the stanza failed.

Even when there is no traffic, send an at least every 5 minutes to check the connection. If there is no inbound traffic (such as an ) within timeout (default 60 seconds) then consider the connection disconnected.