File Sharing Service Like Dropbox Or Google Drive — How To Tackle System Design Interview

Think Software
9 min readJan 19, 2021

Dropbox is a cloud file storage service. It enables users to share the files across their devices and also with remote storage servers. It does that by allowing the users to create special folders on each of their computers or mobile devices, which the service then synchronizes so that it appears to be the same folder regardless of which computer is used to view it. Files placed in this folder also are typically accessible through a website and mobile apps and can be easily shared with other users for viewing or collaboration.

Functional Requirements:

The Dropbox service has the following functional requirements.

1. Users need an account to use the Dropbox service. There are two types of users.

· Free Users — have limited capabilities, a limited number of devices supported, limited network bandwidth and storage

· Premium Users — have more capabilities, a greater number of devices supported, more network bandwidth and storage as compared to free users

2. A User can create a root folder (also called a home folder) in his cloud storage and map it to his devices. Any update (file or folder create/update/delete) that happened in one device under that root folder is synchronized automatically across all the devices of the user. We will call this root folder and all the files and folders under the root folder to belong to a user’s home namespace. A Dropbox namespace is a collection of files and folders that are within a user’s root folder or in a folder shared among multiple users.

3. The maximum file size supported is 1GB. This is an artificial limit that we have imposed but changing this limit has some consequences as discussed later in this chapter.

4. A user should be able to share files or folders with other users. Once a file or folder is shared with other users, any updates to the file or the folder is synchronized automatically to all the devices of the other users.

5. Sharing of a folder enables sharing of all files and sub-folders under that folder.

E.g., consider the following two users userA and userB with their file and…