strava-engineering
Published in

strava-engineering

Building Local Legends

The Birth of a New Feature at Strava

A New Way to Compete

Our team participating in a workshop to explore product development ideas

Can We Build It?

An early design iteration of Local Legends
SELECT athlete_id, COUNT(*)
FROM SEGMENT_EFFORTS
WHERE segment_id = ?
GROUP BY athlete_id
ORDER BY COUNT(*) DESC
SELECT athlete_id, effort_count
FROM LOCAL_LEGEND_LEADERBOARDS
WHERE segment_id = ?
ORDER BY effort_count DESC LIMIT ?

Iterating on Our Designs

Histogram of athletes grouped by number of efforts on a Central Park segment
Linear vs log scale (y-axis) histogram

Engineering a Solution

SELECT athlete_id, effort_count
FROM ROLLING_LOCAL_LEGEND
WHERE segment_id = ? AND date = ?

Implement the Solution

Ship It!

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store