开发者

Tornado websockets: share open web sockets between processes

开发者 https://www.devze.com 2023-03-15 11:50 出处:网络
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开发者_StackOverflow from Django applic

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开发者_StackOverflow from Django application). What is the easiest way to achieve this?


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/.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号