|
Emmanuel Bernard, I see the following cases where it would be useful (in descending importance):
-
Loading elements of a *-to-many association. Currently we go to the store for each element. IMO it's actionable on our side; as you say we'd need to adapt the loaders in OGM
-
Loading entities of HS query results; Currently we do FIND_BY_ID look-ups as we don't implement the Criteria API. If HEARCH allowed for plugging in custom retrieval strategies, we could implement a more efficient one based on the proposed method (currently one can only choose between FIND_BY_ID and QUERY; So this requires some action in HSEARCH first)
-
Batch fetching of *-to-one / *-to-many associations, e.g. when iterating over a result set of an entity with a lazy *-to-one assocation to another entity, load these referenced entities in @BatchSize-sized chunks; I'm not sure what'd have to be done for that
At least the first one would be great to get solved soon as it is an apparent performance issue.
|