Hacker News new | ask | show | jobs
by tomeric 5525 days ago
The IdentityMap makes sure that there is only 1 ActiveRecord instance for a given row in the database.

This basically means that calling Article.find(3) and Comment.where(:article_id => 3).first.article both return the same instance.