From 276eda908e9673c9c6c89010f27fa80f4838f142 Mon Sep 17 00:00:00 2001 From: Ryan Sanford <ryansanford@flywheel.io> Date: Wed, 13 Jan 2016 07:01:05 -0600 Subject: [PATCH] Add comments to clarify intent Clarify the intent of both 'j' and 'connect' options of pymongo.MongoClient(). closes #123 --- api/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/config.py b/api/config.py index 83466642..e9cc9295 100644 --- a/api/config.py +++ b/api/config.py @@ -75,10 +75,10 @@ if not os.path.exists(__config['persistent']['data_path']): db = pymongo.MongoClient( __config['persistent']['db_uri'], - j=True, + j=True, # Requests only return once write has hit the DB journal connectTimeoutMS=__config['persistent']['db_connect_timeout'], serverSelectionTimeoutMS=__config['persistent']['db_server_selection_timeout'], - connect=False, + connect=False, # Connect on first operation to avoid multi-threading related errors ).get_default_database() log.debug(str(db)) -- GitLab