Not sure which versions are precisely affected.
See the attached file. One cannot define bi-directional relations like that:
class Library include Mongoid::Document has_many :relation, class_name: "Book", inverse_of: :relation end class Book include Mongoid::Document belongs_to :relation, class_name: "Library", inverse_of: :relation end
It results with inconsistent behaviour. On the assignment attempt, one side of the relation will not be saved, and sometimes stack overflow error may be raised.