persistence@glassfish.java.net

Re: Disable TopLink caching

From: Markus Fuchs <Markus.Fuchs_at_Sun.COM>
Date: Wed, 23 Aug 2006 11:06:01 -0700

Hi Tom,

How can a non-extended persistence context be specified in JPA? I
understand your answer that toplink.cache.type.default can be used to
achieve this goal as it applies to the ServerSession cache, which
implements the caching btw. transactions functionality, correct?

Thanks,

-- markus.

Tom Ware wrote:

> Hi Markus,
>
> In JPA, when using an extended persistence context we will cache
> between transactions.
>
> The toplink.cache.type.default property affects the caching of the
> TopLink ServerSession that underlies the EntityManagerFactory.
> EntityManager's using an extended persistence context will be based on
> a TopLink UnitOfWork which, in order to maintain object identity, has
> a more complete cache.
>
> -Tom
>
> Markus Fuchs wrote:
>
>> Hi Tom,
>>
>> Is it possible to disable TopLink's between transactions cache by
>> setting
>>
>> <property name="toplink.cache.type.default" value="NONE"/>
>>
>> in persistence.xml?
>>
>> Thanks,
>>
>> -- markus.
>>
>>
>>
>>