delivery Flashcards
(22 cards)
Framework: step 1
Requirements
Framework: step 2
Core Entities
Framework: step 3
API or interface
Framework: step 4
Data flow
Framework: step 5
high level design, satisfy functional requirement
Framework: step 6
deep dives, satisfy non-functional requirements
Type of Requirements
Functional and non-functional
Functional Requirements format
Users/Clients should be able to…
Non-Functional Requirements format
The system should be able to…
checklist to consider
CAP Theorem, Environment Constraints, Scalability, Latency, Durability, Security, Fault Tolerance, Compliance
CAP Theorem
Should your system prioritize consistency or availability? Note, partition tolerance is a given in distributed systems.
Environment Constraints
Are there any constraints on the environment in which your system will run? For example, are you running on a mobile device with limited battery life? Running on devices with limited memory or limited bandwidth (e.g. streaming video on 3G)?
Scalability
All systems need to scale, but does this system have unique scaling requirements? For example, does it have bursty traffic at a specific time of day? Are there events, like holidays, that will cause a significant increase in traffic? Also consider the read vs write ratio here. Does your system need to scale reads or writes more?
Latency
How quickly does the system need to respond to user requests? Specifically consider any requests that require meaningful computation. For example, low latency search when designing Yelp.
Durability
How important is it that the data in your system is not lost? For example, a social network might be able to tolerate some data loss, but a banking system cannot.
Security
How secure does the system need to be? Consider data protection, access control, and compliance with regulations.
Fault Tolerance
How well does the system need to handle failures? Consider redundancy, failover, and recovery mechanisms.
Compliance
Are there legal or regulatory requirements the system needs to meet? Consider industry standards, data protection laws, and other regulations.
REST core entities
POST /v1/tweet
body: {
“text”: string
}
GET /v1/tweet/:tweetId -> Tweet
POST /v1/follow/:userId
GET /v1/feed -> Tweet[]
key components in diagram
client, api gateway, services, database
relevant component
ML inference layer
word for fetching list of items
pageSize, cursor