-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Lazy and Eager loading in Hibernate Tools Console
PostPosted: Tue Mar 28, 2006 9:44 am 
Newbie

Joined: Thu Apr 15, 2004 5:53 pm
Posts: 13
Haven't started experimenting with Hibernate Tools yet, as we're just on the cusp of upgrading to 3.X. One of the things I'm curious to learn is whether or not Hibernate Tools' console view gives any information about lazy loading / eager fetching. Since the difference between these, in both directions, can be important from a performance point of view, it would be handy to be able to test queries' response with respect to these.

Is that something you can easily do in the console?

_________________
--
Geoffrey Wiseman


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 29, 2006 3:27 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
What information do you want ?

Today the only usefull thing you get in this respect is the dynamic query translator view which shows you the sql that will be executed for a given query.

I also want to somehow show what part of the result that is proxied and not yet initialized, but I have not gotten around to implement that yet.

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject: What information
PostPosted: Wed Mar 29, 2006 9:31 am 
Newbie

Joined: Thu Apr 15, 2004 5:53 pm
Posts: 13
Yes, basically what you said -- the query's a good start, but the other elements you're talking about would also be useful.

I'd like to know what part of the query results is eagerly fetched vs. lazily loaded, and which objects have proxies and which don't.

I'm not sure if it's possible for an object in the query results to be both proxied and loaded (without code outside the query actually doing the loading), but if so, I'd like to be tell that too.

That'd give me a lot of information in terms of tuning a query to achieve desired results in terms of ensuring that the objects I expect to use have been loaded, and that if I expect a lot of object activity, they will or won't have the proxy overhead.

_________________
--
Geoffrey Wiseman


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 30, 2006 4:58 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
I have information enough to show which objects are full, proxied and proxied+loaded just need to find a way to visualize it.

What I don't have is real information about wether objects were eagerly or lazily fetched.

But you can most likely deduce that from the proxy-state + the sql preview + showing numbers from the statistics generation.

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.