List functional requirements for the system (Ask the chat bot for hints if stuck.)...
Entrance/Exit Service: to track availability
Contactless Payment Service: Users can make payment easily through an online payment portal
Security Service: A monitoring service equipped with senors to protect cars and users.
Parking Allocation Service: Responsible for assigning empty spaces and updating the registry of availability.
Mobile App/User Interface: An easy to use GUI which will allow users to pay, book and see in real-time availability.
List non-functional requirements for the system...
Security
High Availability
Usability
Maintainability
Estimate the scale of the system you are going to design...
3 parking lot systems, 500 spaces each, 1500 spaces total with a turn over rate of 5 spots per day. This gives us 4500 potential users where the GUI could use around 200MB for each user. 450000 * 2 = 900000MB. Around 1 GB for users.
10 cameras per system = 30 cameras at around 1GB per day with a 2 month holding period = 30GB * 60 = 300 * 6 = 1.8TB
Define what APIs are expected from the system...
https://getParkingSpots/locationID
https://getParkingSpot/locationID/parkingID
https://startPayment/locationID
https://postPayment/locationID
https://getTotalParkinglotCapacity/locationID
https://getSecurityCameras/locationID
https://getSecurityCamera/locationID/cameraID
https://login
https://signup
Defining the system data model early on will clarify how data will flow among different components of the system. Also you could draw an ER diagram using the diagramming tool to enhance your design...
Users Table
Payment Table
Parking Lot Table
Security Camera Table
You should identify enough components that are needed to solve the actual problem from end to end. Also remember to draw a block diagram using the diagramming tool to augment your design. If you are unfamiliar with the tool, you can simply describe your design to the chat bot and ask it to generate a starter diagram for you to modify...
Explain how the request flows from end to end in your high level design. Also you could draw a sequence diagram using the diagramming tool to enhance your explanation...
The User:
Dig deeper into 2-3 components and explain in detail how they work. For example, how well does each component scale? Any relevant algorithm or data structure you like to use for a component? Also you could draw a diagram using the diagramming tool to enhance your design...
Load Balancer
API Gateway
Explain any trade offs you have made and why you made certain tech choices...
Try to discuss as many failure scenarios/bottlenecks as possible.
We may need to introduce NoSql databases in the fture to handle the load.
The payment service may be doing too much. In the future we could implement a receipt service to offload some of this work
What are some future improvements you would make? How would you mitigate the failure scenario(s) you described above?
A new receipt service that retrives data from a cache. This should improvement performance.
We can offload the new receipt service to a new noSQl database where we read the receipt via the userID and the receiptID