-
1. Re: How to cache the table?
adrian.brock Dec 9, 2003 11:11 AM (in response to xf_fong)Your first question is unclear.
I'm guessing the answer is <commit-option>A</commit-option>
For the second question.
findAll is executed against the home interface. This requires
and EntityBean without a primary key.
Each will load the data for their transaction.
All finders except findByPrimaryKey bypass the cache.
Regards,
Adrian -
2. Re: How to cache the table?
xf_fong Dec 10, 2003 1:28 AM (in response to xf_fong)My first question is I want to cache the CMP EntityBean to the memory! In detail: Such as if my CMP EntityBean corresponding a 10000 rows table, Can I cache the whole table's data into the memory?I think that will promote the efficiency! I got somebody's answer is POSSIBLE! I think I sure write something in the deployment descriptors(those xml files)! But I don't know how to do that! Can you help me?
Another question is how can I only cache 5000 rows data of the 10000 row table?
Thanks! -
3. Re: How to cache the table?
adrian.brock Dec 10, 2003 4:25 AM (in response to xf_fong)This article explains caching, in particular commit-option A
i mentioned before.
http://www.onjava.com/pub/a/onjava/2003/05/28/jboss_optimization.html?page=1
There is nothing to preload a table into memory.
You would have to extend something in the jboss cmp engine
to do this.
You could do it manually, but less efficiently with a findAll
then a get() on each some field for each primary key.
Regards,
Adrian