I know for a fact that i am not accessing any fields from any of the many-to-one objects. i turned on the debug and looked at the output and i am still not sure why it is forcing the associations to be lookedup. here is a little of the debgu output:
first the sql for the main object is run then....
14:29:06,814 DEBUG SessionImpl:2202 - resolving associations for [edited/myobject#9000]
14:29:06,814 DEBUG SessionImpl:1986 - loading [edited/mysubobject#2500]
14:29:06,844 DEBUG SessionImpl:1986 - loading [edited/mysubobject2#12906]
14:29:06,844 DEBUG SessionImpl:3933 - creating collection wrapper:[edited/mysubcollection#9000]
14:29:06,864 DEBUG SessionImpl:2226 - done materializing entity [edited/myobject#9000]
14:29:06,864 DEBUG SessionImpl:3116 - initializing non-lazy collections
14:29:14,601 DEBUG SessionImpl:2083 - attempting to resolve [edited/mysubobject#2500]
14:29:14,611 DEBUG SessionImpl:2116 - object not resolved in any cache [edited/mysubobject#2500]
14:29:14,611 DEBUG EntityPersister:416 - Materializing entity: [edited/mysubobject#2500]
after this the sql for subobject1 and subobject2 are ran.
|