change sqlite into mongoid