mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
added session validation to get_mongo_connection
This commit is contained in:
parent
f4e58771a2
commit
0dec31288b
1 changed files with 2 additions and 0 deletions
|
|
@ -156,6 +156,8 @@ class OpenPypeMongoConnection:
|
|||
# Naive validation of existing connection
|
||||
try:
|
||||
connection.server_info()
|
||||
with connection.start_session():
|
||||
pass
|
||||
except Exception:
|
||||
connection = None
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue