[JDEV] Heartbeat patch for dialup and laptop users and faulty presence info

Nathan Sharp spamnps+jabber at phoenix-int.com
Tue May 28 20:38:57 CDT 2002


Thanks so much to Bernd and Perry for backing me up here with better 
arguments that I originally made.  This is incredibly important if you 
have any dial-up users.  I had a case on one of my servers where a user 
showed up as online for more than 12 hours after I know they were 
disconnected!  The solution I've given so far fixes this so that it is 
now down to a maximum of 10-20 minutes (which actually has to do with 
the TCP timeout, since I made a ping only solution).  I'd like to 
eventually make that less than 5 minutes using a ping-pong approach.

I think note should be taken that IRC uses such a ping-pong solution. 
 I'd be willing to bet that AOL, Yahoo, and MSN all include such a 
feature as the TCP timeout logic is severely limited (there was a 
discussion of this point a month ago or so on this list).  

Please note that my code includes logic to NOT send a heartbeat when any 
regular packets to or from the client has happened in the last heartbeat 
timeout.  This will limit added bandwidth considerably, which should be 
small compared to the size of all the message and presence information 
that is sent via Jabber.

Perhaps Matthias Wimmer would be willing to re-run his  traffic analysis 
that he recently posted a second time w/ heartbeats turned on for 
comparison.

  Nathan

Bernd Eckenfels wrote:

>A TCP ping is one thing, to detect reset sockets which are idle. On IRC for
>example in addition to the ping, there is also a pong message required
>within a (configurable time frame). The server will simply disconnect the
>connection of no repsonse is received. this requires a echo protocol
>function but is IMHO quite important.
>
>  
>






More information about the JDev mailing list