[System Design] 系统设计 (4) -- Web System Design

299 查看

What happened when you visit www.google.com?

Type URL in browser: www.google.com(domain)
Find the nearest DNS server(Domain Name Service)
Send http/https request to the IP address
Web Server got the request and deliver it to HTTP server (port 80)
HTTP server resend the request to Django, Rails, NodeJS based Web Application
Web Application processes the request

https://www.djangoproject.com...

HTTP server: Apache, Unicorn, Unicorn, Uwsgi

Design Tiny URL

  • bit.ly

  • Google url shortener

Scenario

  • bit.ly: transform Long URL --> Short URL

  • user: use short URL --> bit.ly

  • bit.ly: return Long URL --> user

  • user: request Long URL to redirect to the website

Needs