I have a problem on my mind. Now when I start with pymongo flask will it try to reconnect to mongodb on every request or will it make a single connection?
It’s a simple question but I just started I want to learn.
I have a problem on my mind. Now when I start with pymongo flask will it try to reconnect to mongodb on every request or will it make a single connection?
It’s a simple question but I just started I want to learn.
PyMongo uses a connection pool, opening connections as needed and reusing them:
https://pymongo.readthedocs.io/en/stable/faq.html#how-does-connection-pooling-work-in-pymongo
This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.