clintongormley / Elastic-Model

Use ElasticSearch as a NoSQL database in Perl
9 stars 8 forks source link

Preload related objects #7

Open clintongormley opened 12 years ago

clintongormley commented 12 years ago

When retrieving objects from a search, only the source for the object itself is retrieved. Often, these objects will refer to related objects, (eg the user object pointed to by a comment object). If the user knows that they will want to access these, it'd be more efficient to do a multi-get, rather than loading each object one by one