System Design - Conference Management
Goals of this article:
How does a Conference Management Application help?
The basic functional requirement of a CM application:
Categories -> Events -> Registration Forms -> Registrations
Non-functional requirement:
System Interface Design, and extended requirements:
Capacity Estimation and Constraints (CEC)
Traffic Estimates
10000/(60*24) = 7 Registrations/minute
Storage Estimates
4*5 = 20 MB file store/registration
领英推荐
40 * 1 = 40 KB
Therefore, each registration takes approx. 21 Mb of file and database storage.
21Mb * 10K * 30 days * 12 months * 10 years = 720 Terabyte of data
This helps in understanding our limit on file uploads of user content.
Bandwidth Estimates
Crucial to balance the load between multiple application servers:
7 Registrations * 21 MB = 147 MB/minute
After some standard unit conversions at 2.45 MB/second data is written to the file system and database.
Reads are mostly in bulk via the server-side registration list by the managers, where a manager can read up to 200 registrations on one page. It is usually the information fetched from the Postgres Database, and files are accessed as one file at a time.
Cache or Memory Estimates
Postgres DB clusters (PgPool II) are powerful to handle multiple large queries per second and currently store the registration information in a redundant de-normalized JSONB column like a Document DB (Mongo DB) that helps in efficient pagination and filtering.
The user's session-related information and some frequently accessed temporary information are stored on Redis (distributed cache).
The operating system or WSGI/ASGI web server might cache the frequently accessed files such as event materials (open to the public) like ppts, or other document files.
Some registrations are frequently accessed by different managers, therefore let's take in the same number of registrations often read i.e 7 for 1 hr of TTL cache.
20 MB * 7 registrations / per minute * 60 minutes = usage of 10 GB of RAM per minute
Done
Things on which we are scaling up and future predictions are not included in these back-of-the-envelope estimates, for example, the number and type of sub-organization being onboarded which bring the number of new events in a month, thus increasing the number of registrations and active users per day.
It's important to regularly monitor the application's performance for adjustments and removing the code or infrastructure-related bottlenecks.
Thanks for reading,