Skip to content

Scaling

Stone Tao edited this page May 28, 2020 · 2 revisions

WIP

To scale a competition, we rely on some fundamental components of web distributed systems designs that make it important and crucial for low cost, efficient competitions. First thing to ask is, what does scaling and distributed systems bring to you? It brings

  • High Availability and Reliability
  • Scalability
  • High Performance
  • Low Cost

Feel free to read this resource for a basic introduction to distributed systems and their power and how to achieve those key listed above.

We will be using the Google Cloud Platform for this introduction and tutorial on how to make Dimensions distributed and scale it up easily.

Dimensions is currently configured to be easily scaled up through Database, Storage plugins (and more to come such as Caching Plugins using services such as Redis). There are many models through which you can scale up Dimensions, we will introduce some of them to solve the problem of running a larger scale competition.

Quick Links: [#model-1](Model 1)

Model 1

The idea is that you have a load balancer sitting in front of servers running the same competition code and dimension.

If you are running a tournament, you can write the same tournament code and upload to each of the servers or use an image from the Google container registry or Docker registry that handles all of the initial setup. We provide some sample docker files in the repository. Furthermore, ensure that you attach a Database plugin and a Storage plugin. Now, setting all of the servers to automatically run the tournament, every server will be running the same tournament code and storing results into the Database together.

With the load balancer, a single call to a single API will return you results efficiently as the balancer will redirect your request to the next available server.

Now, how do we do this on Google Cloud? First, create a Google Account and go to console.cloud.google.com/ and sign up.

There are 3 stages, setting up an instance template, setting up managed instance groups, and setting up the load balancer.

Clone this wiki locally