TokuMX compatibility

Modifications to the MongoDB river to make it work with both vanilla MongoDB and TokuMX.