TinyURL - System Design

CREATED 2021/09/15 22:15 

Basic requirements

1. URL shortening: given a long url, return a short url

2. URL redirecting: given a short url, redirect to the original long url

3. High availability, scalability and fault tolerance

 

API

POST api/v1/data/shorten {longURL} -> {shortURL}

GET api/v1/getUrl {shortURL} -> {Return longURL for HTTP redirection} 301(permanetly and the browser caches the response) 302(temporarily)

 

Store

hash table <shortURL, longURL>

 

上一篇:SDRAM 不帶自動預充電寫操作


下一篇:基于RestAssured实现接口自动化