MongoDB native NodeJS driver - reconnection

In notebook:
Work Notes
Created at:
2015-12-11
Updated:
2015-12-11
Tags:
Just discovered that the native nodejs driver for Mongo DB handles lost connection to the Mongo DB.
You can connect to your db on app initialisation and don't have to worry about it anymore. If your mongo db server restarts the driver will reconnect automatically.

So my strategy for now is to connect once and leave the connection open (don't call ​db.close()​ )