mzupan/nagios-plugin-mongodb — pull request #121 by kovyrin (2014-04-30 11:17:20+00:00)
Title: Only read timestamps from oplog, making the check work with invalid unicode data in the log

In cases when some collection in MongoDb contains invalid unicode data, that data is replicated via the oplog collection and if the invalid record ends up being the first or the last one in the log, all replication-related checks blow up with invalid unicode errors (see https://github.com/10gen-labs/mongo-connector/issues/101 for details):
```
CRITICAL - General MongoDB Error: 'utf8' codec can't decode byte 0xc7 in position 0: invalid continuation byte
```

My small change makes the check script only read the timestamp field from the log so we never touch the actual user data in the log and never blow up on those errors. This has been tested on Swiftype.com servers and seems to be working as expected.