rails 4 has dependecy on activemodel 4.0.0, but mongoid 3.0 and mongoid 3.1.4 has dependency on activemodel ~ 3.1 and ~> 3.2, that's why we should use mongoid 4 version from master for rails 4.