mongodb odm refactoring