hello,

my problem is that I got a table with 500000 records in it and a CMP EJB which has a 
find method.
The JBossCMP doc describes in detail all options for read-ahead, fetch-size, eager-and 
lazy load groups and all that.

However, all these optimizations seem to apply only to the loading of individual 
records. A find query first reads in ALL PrimaryKey fields for the complete resultset, 
instead of just reading in the first few matches.

So, if my ejb find method has two params which, lets say I set to '%', so that the 
method will match the complete resultset of 500000 records, then I cannot page through 
this resultset because JBoss tries to prefetch all 500000 PKs, even if I just try to 
iterate through the first 10 records of the returned collection.

Can someone help me here? 
I assume that every person working with CMP on JBoss must have come by this problem 
for it is surely inacceptable to prefetch PKs for a complete resultsets in cases where 
the size of the resultset can vary and is not know a-priori.

Thanks a lot!

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3823113#3823113

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3823113


-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to