【问题标题】:Websocket for wsgi, which compatible with werkzeugwsgi 的 Websocket,与 werkzeug 兼容
【发布时间】:2012-09-10 21:12:57
【问题描述】:

需要与 werkzeug 兼容的 websocket wsgi 库。

【问题讨论】:

    标签: websocket wsgi werkzeug


    【解决方案1】:

    我最近破解了 Werkzeug 调试器,因此它可以很好地与 gevent-socketio 配合使用:

    https://github.com/aldanor/SocketIO-Flask-Debug

    【讨论】:

      【解决方案2】:

      如果您刚刚开始,您还可以查看gevent,尤其是gevent.socketio

      http://gevent-socketio.readthedocs.org/en/latest/index.html

      看看下面的教程,有点长,但它给了你很好的方法。

      http://blog.pythonisito.com/2012/07/realtime-web-chat-with-socketio-and.html

      【讨论】:

        【解决方案3】:

        Twisted 提供了一个 WSGIResource 来在 Twisted Web 下运行。 Autobahn 提供了一个在 Twisted Web 下运行的 WebSocketResource。所以你可以将两者结合起来(我已经做到了) - 如果这就是你所说的“websocket wsgi库”的意思。

        对于后者:https://github.com/tavendo/AutobahnPython/tree/master/examples/websocket/echo_site

        免责声明:我是 Autobahn 的主要作者,为 Tavendo 工作。

        【讨论】:

          猜你喜欢
          • 2021-01-05
          • 1970-01-01
          • 2012-01-05
          • 1970-01-01
          • 1970-01-01
          • 2012-02-23
          • 2020-06-04
          • 2011-02-13
          • 2011-10-11
          相关资源
          最近更新 更多