Hacker News new | ask | show | jobs
by ClassicFarris 4475 days ago
Hey, I'm interested in my you have Redis, MySQL and Couchbase? That's three database technologies for this project? I can see Redis being used like Memcache… but how are you using MySQL and Couchbase together. I'm interested in that interaction.
1 comments

Thanks for the interest! For MySQL I wanted an easy ORM layer for team, conference and player data. Essentially those 3 objects are stored in MySQL. For redis, I use ordered lists for sorting and easily discerning indexes of team and player data, eg: how I come up with "n overall" and "n in conference" http://madness.io/teams/fak

For Couchbase, all game data is stored in a document, including player stats. I actually use Couchbase as a cache layer as well instead of Redis. Voting and some cache keys are documents and I write couchbase views or use traditional get's to grab that data. Couchbase does the map reduce to give me the numbers I need to come up with all the stats you see on the site. It also comes in handy for things like standard deviation and the tempo-free stats on the matchup pages

Hopefully that helps!