mirror of
https://github.com/viq/NewsBlur.git
synced 2025-04-13 09:38:09 +00:00
Fixing bad instrumentation on mongo and redis logs.
This commit is contained in:
parent
a4ae23c34f
commit
0e63da2d74
3 changed files with 2 additions and 0 deletions
Binary file not shown.
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 33 KiB |
|
@ -27,6 +27,7 @@ class MongoDumpMiddleware(object):
|
||||||
# save old methods
|
# save old methods
|
||||||
setattr(MongoClient, '_logging', True)
|
setattr(MongoClient, '_logging', True)
|
||||||
if hasattr(MongoClient, '_send_message_with_response'):
|
if hasattr(MongoClient, '_send_message_with_response'):
|
||||||
|
connection.queriesx = []
|
||||||
MongoClient._send_message_with_response = \
|
MongoClient._send_message_with_response = \
|
||||||
self._instrument(MongoClient._send_message_with_response)
|
self._instrument(MongoClient._send_message_with_response)
|
||||||
MongoReplicaSetClient._send_message_with_response = \
|
MongoReplicaSetClient._send_message_with_response = \
|
||||||
|
|
|
@ -19,6 +19,7 @@ class RedisDumpMiddleware(object):
|
||||||
if not getattr(Connection, '_logging', False):
|
if not getattr(Connection, '_logging', False):
|
||||||
# save old methods
|
# save old methods
|
||||||
setattr(Connection, '_logging', True)
|
setattr(Connection, '_logging', True)
|
||||||
|
connection.queriesx = []
|
||||||
Connection.pack_command = \
|
Connection.pack_command = \
|
||||||
self._instrument(Connection.pack_command)
|
self._instrument(Connection.pack_command)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue