Skip to content

Instantly share code, notes, and snippets.

View gnpkrish's full-sized avatar

Narayanaperumal gnpkrish

  • tranquil informatics pvt ltd
  • Bangalore
View GitHub Profile
@gnpkrish
gnpkrish / tornado_websocket_ee.py
Created January 15, 2014 12:23
Realtime Communicating with front-end using simple EventEmitter. With use of Tornado + Websocket.
"""
This is a simple example of WebSocket + Tornado + Simple EventEmitters usage.
Thanks to pyee by https://github.com/jesusabdullah
@Author:: Narayanaperumal G <[email protected]>
"""
import tornado.httpserver
import tornado.websocket
import tornado.ioloop
import tornado.web
from collections import defaultdict