Home | Articles | CV (pdf | short)
<2013-12-02> by Lorenzo

Tornado Redis chat

redis is often described as an "in-memory persistent key-value store", but it's much more than that. One of its nicest features is its support for the Publish/Subscribe messaging paradigm, which makes it easy to implement, for example, a chat server.

In order to learn how to use it, I decided to implement a chat server using Redis and Tornado. This is a classical exercise, and others have done the same: but their solution has some pitfalls that I tried to fix.

The code is forked from pelletier's, with some improvements:

This is the code, available also on gist: