Hello, I'm wondering how to lineary scale an audio/video chat (fms /red5) application.
I see 2 possible scenarios : Scenario 1 : I have a loadbalancer (foundry) witch randomly connect clients to a pool of FMS / Red5 servers. Once connected the user hook on a shared object that contain a list of connected users. All servers has an "inter-server" netconnections open they share "connects / disconnects" in order to maintain their user lists. When user send text messages they get proxied to other servers using the "inter-server" nc. This is quite similar to IRC network structure. So for text chat its very easy to scale . The problem appears when a user want to see a video feed that get published on another server than the server where he has his "Main" connection in this case he need to open a "secondary connection" in order to watch the feed. Its easy to store in the main shared object witch contain the list of connected users the rtmp of the corresponding feed. Then when the user is "over" with this feed he close his "secondary connection". => Problems : need to maintain the "inter-server" nc(s) and manage the servers going up / down , etc ... => Pros : Scale pretty well Scenario 2 : All servers in the cluster are independent . The user fetch a list of availaible servers and connect to all of them. When user send text message he "repeat" it in foreach(nc) loop . He build his own "connected users list" by appending all connected users on all servers . When the user want to watch a stream he hook on the right nc . => Problems : All servers has all users connected (licence problem with fms) alot of wasted ram with red5 => Pros : No inter-server communication , no need to manage dead servers as when a server goes down the corresponding users simply reconnect to the next alive one and all other users rebuild their online list after the corresponding nc.onSync . What are the other possible ways ? Ps : in my case i have an one huge chatroom with 3000 users so i cannot spread them in small chatrooms. thanks
_______________________________________________ osflash mailing list [email protected] http://osflash.org/mailman/listinfo/osflash_osflash.org
