Mike on Tap APIs, Code, & Beer... What more do you really need?

0

Socket.io cluster with nginx as reverse proxy

Node.js by default runs on a single process and at max utilizes one CPU. To take the full advantage of a multi core system, multiple node processes can be run with a frontend proxy interfacing with the client. This scenario can be supported in node.js using the cluster module. However with websocket additionally it is […] http://intellisignals.wordpress.com/2015/01/03/socket-io-cluster-with-nginx-as-reverse-proxy/

0

Tornado Error Handling

I thought I’d keep posting my interesting tidbits about Tornado development and simple helpers here.  I found the need for some custom error messages, and along with everything else, really a need for a more robust base request handler… So I wrote one!  The premise is simple: Use this handler as your base class for ALL of your handlers and voila! Simple error handling.  This particular example only handles 404, but that’s because it’s an example.  Feel free to handle any and all codes you may choose with this: # Simple Tornado base handler with error handling class BaseHandler(tornado.web.RequestHandler): def...

0

Tornado Sessions with Redis!

So, first let me say… I love Tornado.  Love it.  It’s simple, it’s easy, it’s asynchronous and non-blocking! What’s not to love? For me, I particularly have a fondness for Redis and using it for reliable web session storage and access.  Whether you love it or hate it, I could care less, but I personally like it and it suits my needs quite well for most projects. So taking these two technologies and using the awesome power of Tornado, and the great “No-SQL” (p.s. “No-SQL” is a stupid term) Redis and merging the two sounded like a pretty great idea.  There...

0

Creation…

Well… I finally got around to creating the “Web of Mike”! I fully expect highly random articles around code, music, life, and whatever crazy idea comes to mind… So here we go!