Sexchat bei facebook
Note that approach (a) changes the sending a chat message / loading a Facebook page from a one-to-one communication into a multicast to all online friends, while approach (b) ensures that users who are neither chatting nor browsing Facebook are nonetheless generating server load.
Another challenge is ensuring the timely delivery of the messages themselves.
Surfacing connected users' idleness greatly enhances the chat user experience but further compounds the problem of keeping presence information up-to-date.
Each Facebook Chat user now needs to be notified whenever one of his/her friends (a) takes an action such as sending a chat message or loads a Facebook page (if tracking idleness via a last-active timestamp) or (b) transitions between idleness states (if representing idleness as a state machine with states like "idle-for-1-minute", "idle-for-2-minutes", "idle-for-5-minutes", "idle-for-10-minutes", etc.).
Even without accounting for the sizeable overhead of spawning an OS process that, on average, twiddles its thumbs for a minute before reporting that no one has sent the user a message, the waiting time could be spent servicing 60-some requests for regular Facebook pages.
The result of running out of Apache processes over the entire Facebook web tier is not pretty, nor is the dynamic configuration of the Apache process limits enjoyable.
For Facebook Chat, we rolled our own subsystem for logging chat messages (in C ) as well as an epoll-driven web server (in Erlang) that holds online users' conversations in-memory and serves the long-polled HTTP requests.
Both subsystems are clustered and partitioned for reliability and efficient failover. In short, because the problem domain fits Erlang like a glove.
Why get bogged down with inconvenient registration pages when you don’t have to?This isn't by any means a new technique: it's a variation of Comet, specifically XHR long polling, and/or BOSH.Having a large-number of long-running concurrent requests makes the Apache part of the standard LAMP stack a dubious implementation choice.The project I'm currently working on, Facebook Chat, offered a nice set of software engineering challenges: The most resource-intensive operation performed in a chat system is not sending messages.It is rather keeping each online user aware of the online-idle-offline states of their friends, so that conversations can begin.
Search for Sexchat bei facebook:
for free chat rooms features, amazing online chat rooms, and mobile chat at the click of a mouse.