[Standards-JIG] Re: What happened to the ACK proposal?

David Chisnall theraven at sucs.org
Mon Aug 15 21:49:27 UTC 2005

On 15 Aug 2005, at 22:34, Sander Devrieze wrote:

> What about "JEP-0079: Advanced Message
> Processing" (http://www.jabber.org/jeps/jep-0079.html)?

This allows someone to detect if a message gets to my server, and my  
server puts it in the TCP-stream.  If, however, my TCP connection has  
dropped then the message will be silently lost (as far as I can  
tell).  What would be more useful would be something along the  
following lines:

I tell the server I want reliable delivery mode.
The server adds a <sequence /> tag to each message containing the  
number of the message.
Every n messages, I reply with a message addressed to the server  
containing the last <sequence /> tag I have received.
Messages are not deleted from the server until they are acknowledged.
Before I disconnect, I should acknowledge all of the messages I have  

If I disconnect at any point, then the server should place all  
messages that have not been acknowledged into my offline store.

I do not need to acknowledge every message, since TCP guarantees  
delivery and order unless the connection is lost, hence if I have  
received one message I must have received all of the messages before it.

I frequently lose messages if I forget to disconnect from my Jabber  
server before moving my laptop between networks - the server thinks  
that my client is still online and doesn't discover that it is not  
until it has received a socket error, which it only gets after it has  
not received ACKs for around a minute (depending on the OS).  This is  
not a `corner case,' this is a real case which occurs often.  It is  
even worse for people on modems - one of the users on my server  
frequently lost messages because his ISP disconnected every 2 hours  
and the server didn't notice this until a minute later.

Note that shorter timeouts is not an option, since on most systems  
the timeout is a system-wide setting, and can not be tweaked by an  
individual program.  Mandating that every operating system which  
wants to have a Jabber client implements a different socket API to  
the Berkley sockets that everyone has been using since ARPANET is  
likewise not an option.

More information about the Standards mailing list