Bugs item #665013, was opened at 2003-01-09 13:24
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=665013&group_id=22866

Category: JBossCMP
Group: v3.2
Status: Open
Resolution: None
Priority: 8
Submitted By: Markus Menner (morphace)
Assigned to: Nobody/Anonymous (nobody)
Summary: Read ahead

Initial Comment:
Hi,

apparently read-ahead is only working for 1-n
relationships :-(, not for n-1.

In my case I used JB3.2b3 but it is the same with 3.0.4.
My OS: WinXP, JDK 1.4.1_01
Yes, I have the CMP docs ... ;-)

Here my standardjbosscmp-jdbc.xml settings:

      <read-ahead>
        <strategy>on-find</strategy>
        <page-size>500</page-size>
        <eager-load-group>*</eager-load-group>
      </read-ahead>
      
      <list-cache-max>1000</list-cache-max>

I use commit-option B, instance per transaction
configuration for my CMP EJB's.

I looked at the code, and (I hope that I am right) it's
clear that it does not work, because the read-ahead
mechanism relies on the collection of primary keys (not
foreign keys).

I feel, that it could be (easily ;-)) done by
collecting the foreign keys too and due to the fact
that the current behavior has grave performance loss I
submit it as bug.

Is it okay ?

TX
Markus


----------------------------------------------------------------------

>Comment By: Markus Menner (morphace)
Date: 2003-02-14 11:04

Message:
Logged In: YES 
user_id=472900

Hi Andrew,
it's a definitely a problem of JBossCMP. 

Because of this, I'm looking for an alternative to JBossCMP
(I have to go in production). 

I tested Hibernate as persistance layer and it's easy and fast. 

Thanx
Markus



----------------------------------------------------------------------

Comment By: Andrew May (amayingenta)
Date: 2003-02-14 10:38

Message:
Logged In: YES 
user_id=621150

I'm having the same problem (both 3.0.3 & 3.0.6).

I have 3 entities in a 1-M-1 relationship:
Identity-Licence-Resource. I'm doing a finder on the Licence
entity, and returning value objects that need data from the
Resource entity. So if I find 500 Licences, most of which
are for different Resources there are nearly 500 queries to
the Resource table when iterating on the CMR between the two
entities - read-ahead would be a big improvement. In the
worst case with my current data there's nearly 3000
Licences, each for a different resource, and it takes about
a minute.

With the current performance I've already put a caching
mechanism in place, but I'm not having to consider
pre-populating the cache so that no users suffer the long delay.

I have had better luck with 1-M read-ahead - this gave me a
big performance boost.

There's a thread in the forums:
http://www.jboss.org/forums/thread.jsp?forum=46&thread=25630

-Andrew

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=665013&group_id=22866


-------------------------------------------------------
This SF.NET email is sponsored by: FREE  SSL Guide from Thawte
are you planning your Web Server Security? Click here to get a FREE
Thawte SSL guide and find the answers to all your  SSL security issues.
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to