开发者

What the "Channel" mean in facebook chat application?

开发者 https://www.devze.com 2023-01-26 09:48 出处:网络
Facebook uses publish/subscribe pattern for their chat app. I used Firebug to catch request in facebook site and I saw that every request to receive message from facebook server almost link to an addr

Facebook uses publish/subscribe pattern for their chat app. I used Firebug to catch request in facebook site and I saw that every request to receive message from facebook server almost link to an address with pattern : http://[number].[numbe开发者_Python百科r].chanel.facebook.com. There is about 0->20 channels which mean number in address pattern will range in [0-20]. I don't know why they need to use channel as subdomain ? Does it relate to divide processing chat message to multiple service (server) to increase server performance ? or just a subdomain name ? What is your opinion ? I'd like to hear your interesting idea on this.


I believe they use sub-somains because there's a limit on how many connections per domain a browser can keep open.

See How many concurrent AJAX (XmlHttpRequest) requests are allowed in popular browsers?

So, those sub-domains are not "channels".


These are special servers which handle only chat messages and notifications. Source: Rodrigo Schmidt's lecture (https://www.facebook.com/rodrigo)

0

精彩评论

暂无评论...
验证码 换一张
取 消