Per year: 1 TB * 365 = 365 TB
RPS = 500000 / 24 * 60 * 60
peak RPS assuming 10% increase from daily = RPS * 1.1 = 500000 * 1.1 / 24 * 60 * 60
peak RPS assuming special event for double views = RPS * 2 = 500000 * 2 / 24 * 60 * 60
Functions:
/netflix/user POST (create_user)
/netflix/user?user_id GET (get_user_data)
/netflix/video?video_hash GET (watch_video)
/netflix/video POST (upload a video)
/netflix/video/lookup POST (lookup videso by tags, metadata etc.)
/netflix/video/like?video_hash POST (like a video)
/netflix/video/comment?video_hash POST (post a comment on a video video)
/netflix/videos/recomendation?user_id GET (get recomended videos)
User : +int RecordID PK
User : +int UserID FK
User : +String UserName
User : +String HashedPassword
User : +String Email
User : +DateTime CreatedAt
Video : +int RecordID PK
Video : +int VideoID FK
Video : +String Link
Video : +int LikeID FK
Video : +DateTime CreatedAt
Like : +int RecordID PK
Like : +int LikeCount
Like : +int DisLikeCount
Like : +int LikeID FK
Comments : +int RecordID PK
Comments : +int VideoID FK
Comments : +int UserID FK
Comments : +String Comment
You should identify enough components that are needed to solve the actual problem from end to end. Also remember to draw a block diagram using the diagramming tool to augment your design. If you are unfamiliar with the tool, you can simply describe your design to the chat bot and ask it to generate a starter diagram for you to modify...
Explain how the request flows from end to end in your high level design. Also you could draw a sequence diagram using the diagramming tool to enhance your explanation...
For video encoding:
For recomendations service:
because I expect to have a lot of filter queries
For comment DB reading comments is paginated because the amount of comments is too big
For video upload queueuses are separated by resolution, meaning that high resolution videso get different reserouces than average queues
What are some future improvements you would make? How would you mitigate the failure scenario(s) you described above?