On 2009/07/16, at 10:57, Jonathan Schleifer wrote:
Am 16.07.2009 um 09:39 schrieb Pedro Melo:
You write "solve the presence flood" and to me that reads as there
is a big problem with it. Maybe that problem is obvious to you, but
it really doesn't seem a problem to me. Can you
elaborate exactly what is the problem with presence flood?
Well, basically, it's two problems: The spam of popups when you log
in and the delayed presence.
Thats a client bug IMHO. The first presence with jabber:x:delay should
not generate a notification popup.
The real problem with the presence flood is that they come for about
5 minutes for me. It's like there's one wave of available presences
every 30 seconds. This is kind of annoying if you just connect to
see if somebody is online and don't know "Hm, is that person offline
or haven't I just received the presence yet?"
The 5 minutes part is very strange and I would look at your setup.
My server has a single user, so I start all my S2S connections on
connect, and I never notice nothing like this.
I know that this is also an implementation issue, maybe more of an
implementation issue than a protocol issue. But having a protocol
that sends all initial presences at once would do two things:
1.) Force server developers to cache.
2.) You know when you got all presences and then definitely know if
somebody is online without waiting 10 minutes just in case you
didn't get the initial presence yet.
The 1) is clearly something that might or might not work in practice.
Keeping S2S connections around just so you can cache presences can be
a two-edged sword.
the 2) is possible today. <presence> with jabber:x:delay are "initial"
presences, in response to presence probes. Without a jabber:x:delay,
they are not.
Is there a solution that will provide the same level of information
(show, status, availability, priority and caps) that the current
presence flood provides? And that works in a distributed environment?
It would basically be one stanza that includes all the presences. It
could even keep the presences 1:1.
You are assuming that the server can even have access to all presences
at any point in time...
Think about server restarts. I think Jabber.org has around 500k
accounts. Is the server expected to send a presence probe to each
distinct contact in those 500k roster just to have a clear picture of
each user roster presence just so you can have your single stanza?
Do you really think this is a good idea?
I understand the popup storm, I'm a victim of it sometimes because my
client choose a poor heuristic for deciding if a <presence> is an
initial presence or not, but I think you can solve this with a proper jabber:x:delay
usage.
Best regards,