本文介绍了MongoClient在派生之前打开.仅创建MongoClient烧瓶的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用进程4的uwsgi线程模式运行Flask,还使用pymongo flask_mongoengine和uwsgi说"MongoClient在fork之前打开.仅创建MongoClient"我尝试用connect = False连接,但是结果是一样的
I am running Flask with uwsgi threaded mode with processes 4 and using pymongo also flask_mongoengine and uwsgi says "MongoClient opened before fork. Create MongoClient only "I tried connect with connect=False but the result is same
lazy-apps = true问题已解决,但似乎uwsgi需要更多时间来加载怎样才能获得最佳性能?
lazy-apps = true problem is fixed but it seems that uwsgi needs more time to loadwhat can be done for best performance ?
推荐答案
还有
Mongoengine和pymongo的解决方案
Solutions for Mongoengine and For pymongo
这篇关于MongoClient在派生之前打开.仅创建MongoClient烧瓶的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!