change to mongodb using mongoid