Merge kdkeck's fork of the river back

@aaiyer was wanting completed TokuMX support in #316  @kdkeck created a fork with code that makes more sense to me and includes a unit test, so I'll include it in lieu of #316