Design a real time chat service similar to WhatsApp
Functional Requirements
1. Group chats
2. Send and receive messages in real time
3. Keep old messages in a database so users can view old group chats and messages
4. Notifications, read receipts and typical chat app functionality
Related Problems
A video service (like youtube) has many viewers watching videos. Given a stream of the video IDs that are being watched, we need to find the top K most viewed videos for different periods of time (1 hour, 1 day, 1 month, all time). For the top K videos returned, we also want the count of views during this period.
Design an app like google maps. The app should provide the quickest possible route between two arbitrary locations. It should provide an ETA, estimated time to reach a destination, using current traffic data.
Sending user notifications is a common requirement in system design. Design a notification service for an organization. The system will use shared services for the underlying messaging implementation (email, sms, push notifications, etc) so the actual messaging implementation does not need to be designed. The system should support a user publishing a notification to a single user or groups of users. Notifications can be triggered manually via a web UI or programmatically via an API. Users should be able to view their past notifications they published. If a user is unable to receive a notification, they should still receive it at the next opportunity and not miss the message. The notification service should scale to billions of notifications per day, with messages delivered within a few seconds, with five 9s uptime.
Design a url shortener service (similar to tinyurl).
1. Generate expiring unique short URL from provided URL
2. Redirect users to the correct website when they navigate to the short URL