yes interesting question for which i don't have the answer :( the only thing i know is the dissatisfying option of calling all the object you need, so hibernate will be forced to load them.
tibi Anil Rawat wrote: > hi matt, > > i sorted out the problem as it was not of ram memory but of setting > property lazy="false" in my .hbm.xml files in many places as it was > done to get the associated records without doing extra wrok. So when > the action was called the hibernate was executing all queries till the > last hiearchy for each object for which lazy="false" was given in > .hbm.xml file, So there were lots of lots of quires fired just for a > simple action. > > so how can i get this functionality programitcally at runtime so that > only associated object is retrived rather than retriving all its child > records. > how can i lazy initialize at runtime > > > > On Wed, Sep 16, 2009 at 4:57 PM, Matt Raible <m...@raibledesigns.com > <mailto:m...@raibledesigns.com>> wrote: > > What do you have your memory settings at? I generally recommend at > least 256MB of RAM for Java applications. The JAVA_OPTS on > appfuse.org <http://appfuse.org/> (to run the demos) is set to: > > -Xms256M -Xmx256M -XX:PermSize=128m -XX:MaxPermSize=128m > -Djava.awt.headless=true -XX:+CMSClassUnloadingEnabled > -XX:+CMSPermGenSweepingEnabled -XX:+UseConcMarkSweepGC -server > > Matt > > > On Wed, Sep 16, 2009 at 2:14 AM, Anil Rawat > <anil.rawa...@gmail.com <mailto:anil.rawa...@gmail.com>> wrote: > > i am using appfuse1.93, spring,hiberante and struts 1.2 > i am having an preformance issue with hibernate > > how can i set fetch mode= lazy dynamically at runtime so that > only that class object is called > > because if i use lazy ="true" in hbm.xml file in my parent > class which is called , then hibernate is firing all the query > to its last child and all hiearchy of its child which are not > used at that moment > > and this is causing performance issue and causing my > applicatin to run very slow and sometime java heap space eror > is thrown > > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@appfuse.dev.java.net For additional commands, e-mail: users-h...@appfuse.dev.java.net