Say I have a basic Rails app with a basic one-to-many relationship where each comment belongs to an article:
$ rails blog
$ cd blog
$ script/generate model a
This fails because there is no identity map in Rails 2.3 or 3.0. You can manually fix it by stitching them together.
a = Article.new
c = a.comments.build
c.article = a
a.save!
This is horrible, and what the identity map in 3.1 will help to fix (in addition to performance gains). c.article
and a.comments.first.article
are different objects without an identity map.