Back to course home
0% completed
Vote For New Content
Solving Hash Collision for URLs
Krish
Aug 14, 2023
The idea to use md5 hash in the first place was to have a unique values with very low collision for urls. So when we are actually using the first 6/7 chars of the base64 encoded version of this hash, theoretically there's a good chance of the key collision with the first 6/7 chars. In case of the collsion for 2 urls (having the same first 6 chars), what is the best way to generate a unique key?
0
0
Comments
Comments
S
Sid a year ago
They mention swapping out chars in case of collision.
On this page
- Why do we need URL shortening?
Try it yourself
Designing URL Shortener (video)
- Requirements and Goals of the System
- Capacity Estimation and Constraints
- System Interface Definition
- Create Short URL API
- Redirect API
- Analytics API
- URL Management API
- Delete Short URL API
- Database Design
- Basic System Design and Algorithm
a. Encoding actual URL
b. Generating keys offline
- Data Partitioning and Replication
- Cache
- Load Balancer (LB)
- Purging or DB cleanup
- Telemetry
- Security and Permissions