solves NoMethodError: undefined method `metadata' for model.
uses .relation_metadata instead of .metadata.
Document#metada as be renamed to Document#relation_metada in mongoid 4.0.0