Skip to content

App Architecture

October 18, 2015

I’ve worked out the general structure of the application. The website front end pulls snapshots, single day data files of the simulation, from S3 or a similar flat cloud storage system. The user clicks these snapshots and the data is rendered using HTML5 canvas. The user can then either request more years of simulation from the selected date or creates a new simulation.

A new simulation requires world parameters such as name, size, and rotation. I decided to be very controlling over new simulation parameters. Limiting the size to three set sizes, and the rotation to a longitudinal, allows me to control the simulations outcome, as there are fewer edge cases to manage. The previous problem of generating detailed continents for any size is minimized as there are only three sizes to prepare for.


Requesting more ticks simply requires the number of years requested.


Each request would start a ZeroMQ client and send a message to its corresponding zmq server running on the websites EC2 server instance. If the request is received and in keeping with the latest request standard, the front end is sent an OK message to inform the user that the message was received. Each request would contain JSON containing the parameters of the request. Each simulation would be trained on a message queue, creating threads for each new request.


The Plate Tectonics Simulation is responsible for creating the planet as well as progressing tectonics a single tick every some 10,000 plate genetics ticks. Plates move at the rate of fingernail growth, so they are not simulated often. This interdependence of simulations means that the plant and tectonic simulation will be sending each other jobs and will require their own clients to communicate with the Needs Ticks ZMQ Server. This server side request for tick will be almost identical to the front end request for further simulation.

After each request is simulated, the resulting JSON simulation data is sent to the S3 bucket for it to be rendered from the front end.


From → Cosmopolitos

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: