| Users/Projects | What Changes |
|---|---|
| 100 users | Simple diagrams with few actors and use cases. Mostly manual drawing or small tools. |
| 10K users | Need for collaborative tools, version control, and reuse of diagram components. Performance starts to matter. |
| 1M users | Cloud-based platforms with multi-tenant support, real-time collaboration, and integration with other design tools. |
| 100M users | Global distributed systems, heavy caching, AI-assisted diagram generation, and advanced analytics on usage patterns. |
Use case diagrams in LLD - Scalability & System Analysis
At small scale, the bottleneck is usually the tool's ability to handle multiple actors and use cases without clutter. As users grow, the bottleneck shifts to collaboration and version control systems that manage concurrent edits and diagram history. At very large scale, the bottleneck becomes the backend infrastructure supporting real-time updates and data synchronization across many users.
- Small scale: Use simple desktop tools or lightweight web apps.
- Medium scale: Implement collaboration features with locking or operational transformation to handle concurrent edits.
- Large scale: Use cloud infrastructure with horizontal scaling, real-time databases (like Firebase), and CDN for static assets.
- Very large scale: Employ sharding of user data, caching of frequently accessed diagrams, and AI to assist in diagram creation and error detection.
Assuming 10K active users editing diagrams:
- Requests per second: ~167 (assuming 1 edit per user per minute)
- Storage: Each diagram ~100KB, with 10K users and average 5 diagrams each = ~5GB storage
- Bandwidth: Edits and updates ~50KB per request, 167 RPS = ~8.35MB/s (~66.8Mbps)
Scaling to 1M users multiplies these numbers by 100, requiring distributed storage, load balancing, and CDN usage.
When discussing scalability of use case diagram tools, start by identifying user growth and collaboration needs. Explain how concurrency and data synchronization become challenges. Discuss backend scaling, caching, and real-time update strategies. Always relate solutions to user experience and system responsiveness.
Your diagram collaboration backend handles 1000 QPS. Traffic grows 10x. What do you do first?
Answer: Add read replicas and implement caching to reduce database load. Also, consider horizontal scaling of application servers to handle increased concurrent connections.
Practice
use case diagram in system design?Solution
Step 1: Understand the role of use case diagrams
Use case diagrams focus on users (actors) and what they do with the system (use cases).Step 2: Compare with other diagram types
Database diagrams show tables, code diagrams show code structure, hardware diagrams show physical parts, none are use case diagrams.Final Answer:
To show user roles and their interactions with the system -> Option AQuick Check:
Use case diagram = user roles + actions [OK]
- Confusing use case diagrams with class or sequence diagrams
- Thinking use case diagrams show database details
- Assuming use case diagrams show internal code logic
actor in a use case diagram?Solution
Step 1: Identify actor symbol in use case diagrams
Actors are shown as stick figures to represent users or external systems.Step 2: Differentiate other symbols
Ovals represent use cases (functions), rectangles can be system boundaries, diamonds are for decisions in flowcharts, not use case diagrams.Final Answer:
A stick figure representing a user -> Option CQuick Check:
Actor symbol = stick figure [OK]
- Using rectangles for actors instead of stick figures
- Confusing use case ovals with actor symbols
- Mixing flowchart symbols with use case diagram symbols
Customer and Admin, and use cases Place Order, Cancel Order, and Update Inventory. Which use case should only be connected to the Admin actor?Solution
Step 1: Analyze actor responsibilities
Customers place and cancel orders; Admin manages inventory updates.Step 2: Match use cases to actors
Only Admin should connect toUpdate Inventoryas it is a system management task.Final Answer:
Update Inventory-> Option DQuick Check:
Admin-only use case = Update Inventory [OK]
- Connecting customers to inventory updates
- Assuming customers can update system data
- Linking all use cases to all actors
Solution
Step 1: Understand <<extend>> relationship
The <<extend>> arrow shows optional or conditional behavior added to a base use case.Step 2: Interpret actor connection meaning
The actor can perform the base use case; the extended use case happens only sometimes.Final Answer:
The extended use case adds optional behavior to the base use case -> Option AQuick Check:
<<extend>>= optional behavior [OK]
- Thinking <<extend>> means mandatory action
- Confusing <<extend>> with <<include>>
- Assuming <<extend>> defines system boundaries
Member actor that includes an Admin actor managing the system?Solution
Step 1: Identify typical member actions
Members usually borrow and return books, not manage inventory.Step 2: Identify admin responsibilities
Admins add or remove books to keep the library updated.Step 3: Match actions to actors correctly
Member: Borrow Book, Return Book; Admin: Add Book, Remove Book correctly assigns borrowing and returning to Member, and adding/removing to Admin.Final Answer:
Member: Borrow Book, Return Book; Admin: Add Book, Remove Book -> Option BQuick Check:
Member = borrow/return, Admin = add/remove [OK]
- Swapping member and admin roles
- Assigning management tasks to members
- Mixing use cases between actors
Ready to prove it?
Pass the test and this pattern moves unknown
