[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-2309) fetch only the lazy property needed

Steve Ebersole (JIRA) noreply at atlassian.com
Fri May 29 15:38:13 EDT 2009


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-2309?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=33287#action_33287 ] 

Steve Ebersole commented on HHH-2309:
-------------------------------------

nikita, first thanks for the patch.

The changes to Cascade happened to be the first one in the patch so its what I noticed first.  Note sure if this applies to the other uses or not yet.  Because it is always checking against the "full set" of lazy property names from the persister it is currently going to skip lazy properties which have in fact been initialized.

> fetch only the lazy property needed 
> ------------------------------------
>
>                 Key: HHH-2309
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2309
>             Project: Hibernate Core
>          Issue Type: New Feature
>          Components: core
>    Affects Versions: 3.2.1
>            Reporter: German de la Cruz
>            Assignee: Steve Ebersole
>             Fix For: 3.3.x, 3.5
>
>         Attachments: HHH-2309-nikitaAtDoppelgangerDotCom-version1.patch
>
>
> The method AbstractEntityPersister.initializeLazyProperty(..) load all lazy properties when it's called. It would be great if could only load the requested property.
> I think the only change we need is in AbstractEntityPersister.initializeLazyPropertiesFromDatastore(...) and AbstractEntityPersister.initializeLazyPropertiesFromCache(...). We must change them in a way that only the referenced property is loaded.
> After that, we must change AbstractFieldInterceptor.intercept(..) to update in a better way the unitializedFields collection (I mean, removing the actual property only instead of null it).
> Besides. Why in line 777 to 780 a query is executed? I think it isn't necessary.
> Thanks.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list