I wrote, >> From what testing I've done so far, the qualifier isn't put on for >> prefetch queries, which leaves me at the same situation as when using >> my datacontext delegate.
On Tue, Sep 24, 2013 at 1:48 PM, Andrus Adamchik <[email protected]> wrote: > This is bad and is not supposed to happen. Appears to be a bug. I am checking > SelectQueryPrefetchRouterAction, > and it applies *root* entity qualifier to prefetch query instead of > prefetched entity. Should be a relatively easy fix for "disjoint" > prefetches at least. I am closing CAY-1875 as invalid. My original testing of entity qualifiers must have been flawed, possibly due to interactions with other changes I had already made. Once I removed the willPerformQuery code entirely, and disabled my application-level qualifiers completely, the prefetching using entity qualifiers worked as expect in my application. The prefetch entity qualifier is actually added in QualiferTranslator, not in SelectQueryPrefetchRouterAction. That root entity qualifier is rightly inherited from the original query as we don't want to prefetch records for unrelated root entity objects. Sorry for the false alarm.
