Top Songs by Country Leaderboard

System Design · ByteDance · Hard

Design a service that can publish the current top ten songs for any requested country or region. It must also receive a playback event every time a listener starts a track. The listener's region should be resolved from an authenticated profile, IP geolocation, or device context rather than accepted directly from the client as the sole source of truth. Each country or region must have its own ranking, refreshed roughly every ten minutes. Leaderboard reads should complete in…

Loading the rest of the question…