开发者

What library to use for comet in Django?

I'm planning to write a comet application in Django, but as far as I can see articles on this topic are scarce, and the comet libraries that are available don't necessarily lend themselves to use with Django (especially the development environment).

So far the best options I've seen (with one article on how to get it started in Django each) are APE and Orbited. Orbited, however, doesn't seem to still be actively 开发者_C百科developed (easy_install doesn't even work, the domains have expired), and APE should work fine, but how does one get it to work with python manage.py runserver ?

So my question is - if you are writing a comet application in Django, what library is most commonly used, if any?


My solution for this would be to write all of the models and main site in Django, but use another server for the ajax which is more suited to long polling or persistent sockets.

For example: SocketTornad.IO https://github.com/SocketTornadIO/SocketTornad.IO

Inside the tornado socket.io server, the idea was to import the required Django models to work with the data required by the comet / websocket views.

Doing that through manage.py or any plain django server seems very difficult, and it would much easier to let the tornado socket.io server do the specialized comet/websocket work for you.

But, I have not actually implemented it yet, since basic non comet ajax has met our needs fine. It is just a concept that was considered.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜