I find a lot of documentation on the internet about eager loading and optimisations for ActiveRecord, not so much about mongoid.
I'd like to think everything works the same, but that would be too easy, and probably totally wrong in some cases. There are some key differences bewteen ActiveRecord and Mongoid (and not just the embedded stuff), and I'd like to know... what I should know in order to determine whether what I read can also apply to Mongoid or not.
For instance, this link is one of my first results in Google. Can I assume everything that is said about includes
, preload
, and eager_load
can also apply to Mongoid ?
If I want to pull a lot of deep-nested information, how should I proceed for Mongoid ?