JAVA-374 - Logging of entry to and exit from calls to server #107

Closed
wants to merge 1 commit into
from

Projects

None yet

2 participants

@chetanmeh

Adding support for logging the calls made to Mongo DB along with time taken. The message log consist of following part. The logs can be enabled by set the LogLevel for 'com.mongodb.TRACE' category

Request: Id: <sequence number> (<time taken in millis> ms) <operation name>, [<collection name>]

For example below are logs obtained while executing a testcase which consisted of two inserts

FINEST: save:  com_mongodb_unittest_QueryLogTest.test { "key1" : "val1"}
FINEST: Request : Id: 1 (5 ms) OP_QUERY, { "isMaster" : 1}
FINEST: Request : Id: 2 (0 ms) OP_INSERT, [test]
FINEST: save:  com_mongodb_unittest_QueryLogTest.test { "key2" : "val2"}
FINEST: Request : Id: 3 (0 ms) OP_INSERT, [test]
Chetan Mehrotra JAVA-374 - Logging of entry to and exit from calls to server
Adding support for logging the calls made to Mongo DB along with time taken
4b55420
@trishagee trishagee was assigned Mar 12, 2013
@trishagee

We're not going to add this for the 2.x driver, but we do know that there is a need for more logging/monitoring in the driver. This is something that should be addressed in the 3.x driver.

@trishagee trishagee closed this Jul 2, 2013
@trishagee trishagee was unassigned by chetanmeh Dec 23, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment