karmi/retire — pull request #884 by Proghat (2013-10-05 22:13:56+00:00)
Title: Disable mongoid's identity map during importing

Iterating over all documents in collection with enabled identity map will fill memory until task will be killed by OS.

From mongoid doc: "When a document is now loaded from the database, it is automatically added to the identity map by its class and id. Subsequent request for that document by its id will not hit the database, but rather pull the document back from the identity map itself".

See http://mongoid.org/en/mongoid/docs/identity_map.html for additional information about identity map.