Using django and twisted together

1) I want to publish a website that has forums and chats. Chats and forums are connected in some way . The host for each thread that users can chat in this thread or can post a response to the forum. I was thinking about using django for forums and twisting in chat. Can I combine these two? A chat application developed using twisted is associated with a forum.

2) If I use twisted and django, what kind of web hosting is transferred, do I use it when posting to a website on the Internet? Shold do I use VPS? Or can I get a host that supports both?

+5
source share
3 answers

I would not combine the two; calls to Django will happen synchronously, which means that the Twisted event loop will be blocked. It is better to view the Twisted process as a standalone application using Django and have a classic web server that processes the Django application.

You probably won't find a shared host that allows you to run the Twisted app, so I would go along the VPS route.

+12
source

I have a project that may be exactly what you are looking for (at least for a start). It is called Hotdot: http://github.com/clemesha/hotdot .

, : http://clemesha.org/blog/2009/dec/17/realtime-web-apps-python-django-orbited-twisted/

+9

If the application-application needs to get something from the chat application, it is easier to make the application-application communicate with the chat application using simple HTTP requests and force them to run separately.

0
source

All Articles