persistence@glassfish.java.net

Re: Caching-Between-Transactions

From: Marina Vatkina <Marina.Vatkina_at_Sun.COM>
Date: Mon, 14 Aug 2006 16:41:25 -0700

Hi Adam,

Are you asking about CMP or Java Persistence implementation?
They are based on 2 different code bases in glassfish ('cmp'
and 'entity-persistence' sub-modules).

CMP supports version consistency, and as such "caching between
transactions" for those beans that choose to use this consistency
level. It also supports read-only CMPs which states are cached for a
period of time (refresh interval).

JPA implementation always uses "caching between transactions",
and you need to call an explicit refresh, to reload an instance
from a database (like you have by default in CMP).

HTH.

Regards,
-marina

Adam Bien wrote On 08/14/06 08:11,:
> I read the following thread:
> http://www.theserverside.com/news/thread.tss?thread_id=41748
>
> Do glassfish not support the notion of "caching between transactions"
> or commit-option A (from CMP 2.1)?
>
> This is important for real world...
>
> regards,
>
> adam
>
>