-
1. Re: CMP cache problem
haowu Mar 24, 2002 12:19 AM (in response to haowu)I'm going to answer my own question.
The answer lies with the EJB Commit Option. The default cache option is B (for EJB 2.0 CMP). I need to switch to C, if there are external entities (in my case, a MySQL console) update the data.
I found the default in standardjboss.xml. As with everything else, it can be overwritten in application's jboss.xml.
--Hao -
2. Re: CMP cache problem
roysun Mar 25, 2002 6:20 PM (in response to haowu)What does the "B" and "C" mean?
Roy -
3. Re: CMP cache problem
haowu Mar 25, 2002 11:53 PM (in response to haowu)This is my understanding - check out the EJB spec for confirmation:
A - exclusive Read/Write, i.e. no one else will read/write the data. This means Read/Write can access the cache, instead of the DB.
B - exclusive Write, shared Read, i.e. no external updates beside your application. This means Write will go back to DB immediately as there are possible other readers, but Read can pull off cache as no one else is updating.
C - shared Read/Write. Basically not relying on cache. Write goes into DB immediately, even Read will consume from the database. Basically transaction is the scope of caching.
--Hao -
4. Re: CMP cache problem
mgl Oct 22, 2002 10:47 AM (in response to haowu)Where do I specify these options?
-
5. Re: CMP cache problem
adrian.brock Oct 22, 2002 7:21 PM (in response to haowu)jboss.xml
default is in standardjboss.xml
see the dtd or free docs for more info
Regards,
Adrian