Refactor MySQL driver modifs in MongoDB driver