Loading...
Instead of a database, use a simple Redis or similar cache since we just need to look up key/value pairs and let them be long-lived. In this case the pairs are Long URL <- Short URL ID as well as REV lookup to go the other direction at write time
As mentioned above, /u endpoint will add a touch/heartbeat to any entry that is used.
For GC, can set some sort of lifecycle policy, maybe delete entries that have not been used in 30 days or longer