异步消息队列 - 哪种组合?
我一直在尝试确定哪种包组合可用于网站背后的推送消息服务...... 我目前的想法是使用 Tornado + Socket.IO (Tornadio) 和 ZMQ。但我也在考虑让 Mongrel2 参与进来。还有一个类似的项目,名为 Brubeck,它取自 Tornado,使用 ZMQ 和 Eventlet。 我的主要问题是......我试图了解如果我使用 Tornado,Mongrel2 的好处将在哪里发挥作用。到那时,龙卷风还有必要吗?我当时想我只需编写一个 Mongrel2 python 处理程序即可。我想专注于使用 websockets/jssockets,这就是为什么使用 Socket.IO 很有趣,因为它在幕后为您处理所有向后兼容性。
如果要考虑的组合中的工具是:Python focus、Tornado、Mongrel2、ZMQ、Brubeck 和 Socket.IO,您对支持 websockets 的最佳组合有何建议?拥有 Mongrel2 对于可扩展性的想法确实很有吸引力,而且只是打开更多的 python 处理程序。
更新 1/1/2012
起初使用 Tornado + TornadIO + ZeroMQ,并且有一个工作服务器。但最终我最终学习了 Go (www.golang.org) 并使用纯 Go 及其构建的重写了我的服务器在并发中。最终速度比 python 快 10 倍以上,甚至比我的 Python 版本有更多功能:http://www.justinfx.com/2011/07/28/go-language-for-python-programmers/
随着 Go 团队的发展,它似乎在不断加快速度更多 Go 1.0 版本
I have been trying to determine which combination of packages to use for a push messaging service behind a web site...
My current idea is to go with Tornado + Socket.IO (Tornadio) and ZMQ. But I was also looking at involving Mongrel2. Then there is also a similar project called Brubeck, that takes from Tornado, using ZMQ and Eventlet.
My main question is this... I'm trying to understand where the benefit of Mongrel2 would come into play if I were to use Tornado. At that point, is Tornado even necessary? I figured at that point I would just be writing a Mongrel2 python handler and thats it. I would like to focus on using websockets/jssockets which is why using Socket.IO was interesting since it handles all the backwards compatibility under the hood for you.
If the tools in the mix for consideration are: Python focus, Tornado, Mongrel2, ZMQ, Brubeck, and Socket.IO, what recommendations would you have for the best mix to support websockets? Having Mongrel2 was really appealing for the idea of scalability, and just turning on more python handlers.
Update 1/1/2012
At first went with Tornado + TornadIO + ZeroMQ, and had a working server. But ultimately I ended up learning Go (www.golang.org) and rewrote my server using pure Go with its built in concurrency. Ended up being faster than python by over 10x even with more features than my Python version: http://www.justinfx.com/2011/07/28/go-language-for-python-programmers/
It seems to keep on picking up speed as the Go team makes more releases towards Go 1.0
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
听起来像是 Flash/Javascript 绑定的工作。 http://www.zeromq.org/bindings:javascript
这样你就有了一个 ZMQ 应用程序作为任何 PUB 套接字的 SUB 的浏览器正在推送相关消息。
Sounds like a job for the Flash/Javascript binding. http://www.zeromq.org/bindings:javascript
That way you have a ZMQ app in the browser that is a SUB to whatever PUB sockets are pushing relevant messages.
我将自己的更新添加到这个问题作为答案,因为我从未收到任何其他答案,所以我可以关闭这个答案...
起初使用 Tornado + TornadIO + ZeroMQ,并且有一个工作服务器。但最终我最终学习了 Go (www.golang.org),并使用纯 Go 及其内置并发性重写了我的服务器。最终速度比 python 快 10 倍以上,甚至比我的 Python 版本有更多功能:http://www.justinfx.com/2011/07/28/go-language-for-python-programmers/
随着 Go 团队做出更多贡献,它似乎继续加快速度面向 Go 1.0 的版本
I am adding my own update to this question as the answer, since I never received any other answers, and so I can close this one down...
At first went with Tornado + TornadIO + ZeroMQ, and had a working server. But ultimately I ended up learning Go (www.golang.org) and rewrote my server using pure Go with its built in concurrency. Ended up being faster than python by over 10x even with more features than my Python version: http://www.justinfx.com/2011/07/28/go-language-for-python-programmers/
It seems to keep on picking up speed as the Go team makes more releases towards Go 1.0