| Brian Lesser 2005-08-17, 5:46 pm |
| Hi David,
With enough hardware money and developer time I think you can scale most=20
applications as far as you want to. However, in general, you cannot=20
scale an n-way app forever with a root/leaf node architecture. At some=20
point the amount of data passing through the root, or the amount of CPU=20
used, or the amount of memory consumed will be too great. At very large=20
scales you will have to break down the design to group limited numbers=20
of users into more isolated single intances or somewhat larger numbers=20
of users into more isolated groups of instances. After that to really=20
scale I think you need a Web application/Database to maintain state=20
between thousands of instances running on many servers or to carefully=20
limit the amount of information moving between nodes.
Imagine a chess tournament with 20 boards in play at once. Yes, you can=20
easily distribute all the moves between intances so that anyone can see=20
any board at one time. Now imagine a tournament with 300,000 boards all=20
in use at the same time. No way you want to distribute every move in=20
real time to everyone via a root node. So now you have to restirct how=20
many boards each user can watch at one time. How do they know what=20
boards are available? They can query a database for a list of active=20
boards that match the user's search criteria. Similarly with a small=20
system that must handle 1,000 simultaneous users. Its no problem to=20
provide real-time information about who is logged in via root/leaf=20
scenarios. But imagine 10,000,000 simultaneous users. No way a people=20
list can be that long, no way all those updates can go in real time to=20
every instance, and there's no way a shared object can hold so many user=20
records in memory at once. So again you need a different design - for=20
example as in instant messaging - where users select who they are=20
interested in and check those user's current state against a=20
database/web app.
Doing all this will get easier if MM follows through with what they=20
discussed in their FlashCom sneak peek:
http://flash-communications.net/new...Peek/index.html
See the sections on scalability and on the Java and C++ clients. In an=20
IM scenario imagine a trigger in your database being fired whenever=20
someone logs in resulting in messages being sent to the instances=20
individual users who have friended that user are connected to.
Yours truly,
-Brian
David Crebbin wrote:
>Is there a point to which you can only scale so far?
>For instance, building two-way games / lobby
>applications.=20
>
>The scenario:
>
>You build a massively popular game / games. 10=92s of
>thousands of people play at any one time.
>
>If you have a root / leaf tree structure. Obviously
>leaf servers can be added to the root. The root server
>is how information about games etc, is shared between
>servers (proxies). Games are multi-instance
>applications, where a user gets sent to any leaf
>server via a load balancer. So game state will need to
>be synced between instances
>
>The strain will be on the leaf servers, but any
>information to be shared between games will be via the
>root. Is this the right strategy? None of the games
>are simultaneous (car racing) but more multiplayer
>logic. Should players moves be sent via the root. Will
>this cause too much strain on the root server if many
>different games are underway?=20
>
>Is the root / leaf the only solution for two-way
>games?
>
>If anyone has built scalable two way games, or can
>provide some useful pointers, this would be great.
>
>Cheers folks,
>
>Dave
>
>=3D-----------------------------------------------------------
>Supported by Fig Leaf Software - http://www.figleaf.com
>=3D-----------------------------------------------------------
>
>To change your subscription options or search the archive:
>http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
> =20
>
--=20
________________________________________
______________________________
Brian Lesser
Assistant Director, Teaching and Technology Support
Computing and Communications Services
Ryerson University
350 Victoria St.
Toronto, Ontario Phone: (416) 979-5000 ext. 6835
M5B 2K3 Fax: (416) 979-5220
Office: AB48D E-mail: blesser-6s6ziW1YCwCw5LPnMra/2Q@public.gmane.org
(Enter through LB66) Web: http://www.ryerson.ca/~blesser
________________________________________
______________________________
=3D-----------------------------------------------------------
Supported by Fig Leaf Software - http://www.figleaf.com
=3D-----------------------------------------------------------
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
|