-
Type: Improvement
-
Resolution: Done
-
Priority: Minor - P4
-
None
-
Affects Version/s: 3.1.1
-
Component/s: None
-
Environment:Ubuntu 14.04.3, Python 2.7.6
If you fork children from a parent process using the multiprocessing library you may get these warnings:
/usr/local/lib/python2.7/dist-packages/pymongo/topology.py:74: UserWarning: MongoClient opened before fork. Create MongoClient with connect=False, or create client after forking. See PyMongo's documentation for details: http://api.mongodb.org/python/current/faq.html#using-pymongo-with-multiprocessing>
We only use MongoClient to set up data in the parent before forking and don't use it after forking. We even close the Connection before initiating the fork, however we still get those warnings.
There should be some way to suppress them in a use case such as ours.
- related to
-
PYTHON-961 initializing multiple connections from multiprocessing threads causes database connections to fail to be created
- Closed