需要帮助了解彗星在Python(与Django) [英] Need help understanding Comet in Python (with Django)

查看:119
本文介绍了需要帮助了解彗星在Python(与Django)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在这两天花了两天时间,我仍然发现无法理解彗星在Python中的所有选择和配置。我已经阅读了所有的答案以及我可以找到的每个博文。感觉就这样我就要出血了,所以我对这个问题的任何错误都表示歉意。



我完全是全新的,全部我以前做过简单的非实时网站,在Apache上使用PHP / Django后端。



我的目标是创建一个实时聊天应用程序;希望绑定到Django的用户,auth,模板等。



每次我看到一个工具,它说我需要另一个工具在上面它的感觉就像一个永无止境的链条。



首先,任何人都可以对这份工作所需的所有工具进行分类?

I看过不同的服务器,网络库,引擎,客户端的JavaScript,我也不知道还有什么。我从来没有想过会是复杂的。



Twisted / Twisted网络似乎很受欢迎,但是我不知道要整合它或者我需要什么(猜测我至少需要客户端JS)。



如果我明白正确地, Orbited 已经在上修改了 Twisted,我需要其他任何东西吗?



Gevent和Eventlet是否与Twisted属于同一类别?我们需要多少钱?



像Redis这样的Celery,RabbitMQ或KV商店这样做的东西在哪里?我不太明白消息队列的概念。他们提供什么服务?



有没有任何完整的聊天应用程序教程我应该看看?



<对于帮助我过去这个心理障碍的任何人,我将完全感谢,如果我留下任何东西,请不要犹豫。我知道这是一个很好的问题。

解决方案

你可以使用Socket.IO。有几个地龙和龙卷风处理程序。在Django上查看我在gevent-socketio上的博文: http:/ /codysoyland.com/2011/feb/6/evented-django-part-one-socketio-and-gevent/


After spending two entire days on this I'm still finding it impossible to understand all the choices and configurations for Comet in Python. I've read all the answers here as well as every blog post I could find. It feels like I'm about to hemorrhage at this point, so my utmost apologies for anything wrong with this question.

I'm entirely new to all of this, all I've done before were simple non-real-time sites with a PHP/Django backend on Apache.

My goal is to create a real-time chat application; hopefully tied to Django for users, auth, templates, etc.

Every time I read about a tool it says I need another tool on top of it, it feels like a never-ending chain.

First of all, can anybody categorize all the tools needed for this job?
I've read about different servers, networking libraries, engines, JavaScripts for the client side, and I don't know what else. I never imagined it would be this complex.

Twisted / Twisted Web seems to be popular, but I have no idea to to integrate it or what else I need (guessing I need client-side JS at least).

If I understand correctly, Orbited is built on Twisted, do I need anything else with it?

Are Gevent and Eventlet in the same category as Twisted? How much else do I need with them?

Where do things like Celery, RabbitMQ, or KV stores like Redis come into this? I don't really understand the concept of a message queue. Are they essential and what service do they provide?

Are there any complete chat app tutorials I should look at?

I'll be entirely indebted to anybody who helps me past this mental roadblock, and if I left anything out please don't hesitate to ask. I know it's a pretty loaded question.

解决方案

You could use Socket.IO. There are gevent and tornado handlers for it. See my blog post on gevent-socketio with Django here: http://codysoyland.com/2011/feb/6/evented-django-part-one-socketio-and-gevent/

这篇关于需要帮助了解彗星在Python(与Django)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆