Tornado is a web framework on its own, it handles the polling and the replies internally. This nginx module is just a helper to the framework behind it. It keeps the connections to the listeners, waiting for the framework to signal it, and then sends the message back to the listeners.