gpt4 book ai didi

django - 在twisted.web上运行django

转载 作者:行者123 更新时间:2023-12-02 06:57:35 25 4
gpt4 key购买 nike

您将如何在twisted.web react 器上运行Django?我无法在 github 或 sourceforge 上找到任何提供可靠代码示例的权威教程或任何可以使用的内容。我见过钩针编织和其他一些 wrapper ,但它们都很旧并且无法维护。我可以使用 WSGI,但我更想看看是否可以将 Django 作为 react 器运行,并尝试提供 Stdout 和 in 来控制应用程序的其余部分。

最佳答案

嗨凯尔:您可以查看我们在我公司使用的 hendrix,它非常酷,并且可以为您提供帮助,运行 hx start --dev 很简单...并且它使用 Tiempo 另一个进行多线程和监控的很酷的产品... https://github.com/hendrix/hendrix

为什么需要另一个 Python 服务器?

Gunicorn 和 uWSGI 非常擅长它们的工作:监听端口上的请求并将这些请求传递到 WSGI 应用程序。

Instead of being first-and-foremost a WSGI container, Hendrix is first-and-foremost a network engine - a Twisted application.

As such, Hendrix is natively able to do threading, asynchrony, websocket traffic, and speak directly to other services in your architecture.

https://github.com/hendrix/hendrix/tree/master/examples/django_hx_chatserver

关于django - 在twisted.web上运行django,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36850290/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com