Hey guys,
I've been thinking lately about polymorphic associations, and I
wonder: is there a noticeable or tangible performance "hit" from doing
polymorphic associations when you've got your database under really
high query load?
So for example, maybe I have a "message" model, a "user" model and an
"administrator" model, without any subclassing or STI going on.
Message has a polymorphic interface called "message_author", and both
"User" and "Administrator" use it. Say there wind up being ~1 million
messages in that message table. Assuming everything's properly
indexed, do polymorphic associations add any significant overhead to
conducting database queries?
Thanks guys, appreciate the input.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
No comments:
Post a Comment