Vladimir Mihailenco
Vladimir Mihailenco

Reputation: 3382

Tornado websockets: share open web sockets between processes

I have tornado application, that serves websockets connections, and Django app. I want to share open websockets between Django and Tornado (i.e. write to sockets from Django application). What is the easiest way to achieve this?

Upvotes: 3

Views: 800

Answers (1)

Zhehao Mao
Zhehao Mao

Reputation: 1789

Easiest way to do it is to use a tornado.wsgi.WSGIContainer wrapping a django.core.handlers.wsgi.WSGIHandler. There is a good example at http://djangosnippets.org/snippets/1748/.

Upvotes: 1

Related Questions