Part 4 of 9 · 2 min read
The parts a design is made of
The five kinds of parts that nearly every design uses, in one plain line each.
Most designs in this path draw boxes from a short list. Each box has a name and a job. Later levels explain each one in depth. This page only names them, so that the later pages can use the names.
Client
A client is the program the user touches, such as a phone app or a web page in a browser. It asks for things and shows the answers.
Example: the bakery page that shows today's cakes.
Server
A server is a program, running on a computer somewhere else, that waits for requests from clients and sends back answers.
Example: the program that receives "order two loaves" and replies "order saved".
Data store
A data store is a part that keeps information safe so that it is still there after a restart. A database is the most common kind. Level 2 explains databases.
Example: the saved list of every bakery order.
Cache
A cache is a small, fast store that keeps a copy of data that is asked for often, so that the slower store does not have to answer every time. Level 3 explains caches.
Example: a copy of today's cake menu, kept ready because every visitor asks for it.
Queue
A queue is a waiting line for work. One part puts a job in the line, and another part takes it out later, at its own speed. Level 6 explains queues.
Example: "send a confirmation email" jobs wait in a queue, so that a slow email service does not slow down order taking.
A first drawing of the bakery shop uses all five names: the client sends the order, the server checks it, the data store saves it, the cache holds the menu, and the queue holds the email jobs.
Read it as
A box is a job, not a computer. One computer can run several boxes, and one box can run on many computers.
Check yourself:
- Which part would keep a customer's address after a restart?
- Which part would you add if the same menu is requested thousands of times a minute?