Hacker News new | ask | show | jobs
by dc-tech-fan 5144 days ago
Wow, excited to see a shout out on HN for something I created!

I'll try to answer any questions you have, especially technical questions about running a game with thousands of users on Node.

(Edit: spelling)

2 comments

I am really liking the new website, I like the "I would just prefer to make an account" to get around facebook/twitter. I would prefer it to be the default, but I'm really happy you've included that for people who don't have either.

As a sidenote, is Doodle or Die still infested with pictures of sonic going fast?

We have a reporting system to get rid of those few bad apples from 4Chan (amazingly most 4Chan players love the site and play legitimately).
Well a fun game can make anyone sit down to enjoy it I guess.
Great site! Can you tell us about the technology you use to run it, such as db, npm modules, server configs, etc?

Sometimes I wish sites had something like a colophon that described how the site was made.

NPM Modules:

mongodb

async - no more insane levels of nested indents when doing async javascript

express - middleware

ejs - templating system

logging - very simple logging module i wrote more than a year ago when there weren't good logging modules for Node yet.

knox - for storing doodles and static assets on S3

uglify-js - compress that client-side javascript

stylus - much nicer way to write css. variables, functions, mixins, etc.

everyauth - authentication - supports more than we could ever want but we're just exposing Facebook and Twitter for now.

useragent - we only support modern browsers, sorry IE users!

shortid - module I created to give us very short unique ids that are not guessable for chain sharing, like http://doodleordie.com/c/Eih5TDOHk or http://doodleordie.com/c/1hODyac94#1to4

moment - nice time references, like "7 days ago"

canvas - we render doodles on the server and then save those pngs instead of accepting pngs from the browser because people figured out they could send us any image they wanted.

ansi - doodles above a certain number of brush strokes we convert to ansi and echo in our console log. This is my favorite feature of the whole site, especially because I got my start in online communities in the 2400 Baud BBS world when ANSI art ruled.

Database: Mongo

We're using a 5 GB instance at MongoHQ with backups to S3.

Mongo is insane fast compared to what I'm used to with MySQL, and I love the JSON-based query syntax over SQL.

Not being able to do relational-type queries has made some things more difficult, like building "Top 10 List" of arbitrary data is a bit more tedious.

I agree about a colophon!

We have a lot of this information on our About Page but maybe that's not the best place for it.

http://doodleordie.com/about

I'll reply to each technology separately to make it easier to reply to questions about a specific tech.

Server Config: 1 GB of RAM vm at Joyent.

This much ram has been perfect. We've actually had 1000 people playing at once on our first machine which only had 256 MB of RAM.