Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
MongoDBProxy
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
MongoDBProxy
Commits
72b826fd
Commit
72b826fd
authored
Dec 30, 2013
by
Richard Frank
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Proxy executable methods from Database, ReplicaSetConnection
and mongo client classes
parent
6943c2a0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
mongodb_proxy.py
+9
-0
No files found.
mongodb_proxy.py
View file @
72b826fd
...
@@ -26,8 +26,17 @@ def get_methods(*objs):
...
@@ -26,8 +26,17 @@ def get_methods(*objs):
and
hasattr
(
getattr
(
obj
,
attr
),
'__call__'
)
and
hasattr
(
getattr
(
obj
,
attr
),
'__call__'
)
)
)
try
:
# will fail to import from older versions of pymongo
from
pymongo
import
MongoClient
,
MongoReplicaSetClient
except
ImportError
:
MongoClient
,
MongoReplicaSetClient
=
None
,
None
EXECUTABLE_MONGO_METHODS
=
get_methods
(
pymongo
.
collection
.
Collection
,
EXECUTABLE_MONGO_METHODS
=
get_methods
(
pymongo
.
collection
.
Collection
,
pymongo
.
database
.
Database
,
pymongo
.
Connection
,
pymongo
.
Connection
,
pymongo
.
ReplicaSetConnection
,
MongoClient
,
MongoReplicaSetClient
,
pymongo
)
pymongo
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment