I wondering also when the objects in the cache are synchronized with the DB (when a object is refreshed or when a update/insert is made in the DB) ?
Are there different strategies to synchronise with the DB ( eg. for read only objects : avoid intensive retrieve from the DB) ?
I don't see where all these synchronisations with the DB are made in code. Can you point me to the class which is managing that ?

Christophe


Mahler Thomas wrote:

Hi Stefan,


-----Original Message-----
From: Stefan Schl�sser [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 21, 2003 10:51 AM
To: oJB Users List
Subject: Caching of Objects


Hi,

OJB has a build in object cache, after reading its interface, I got the impression that I have to explictly put objects into the cache.
No. The objectcache interface is meant as an SPI not an API. The
PersistenceBroker automatically place objects in the cache on loading and
storing.


This does however not seem to be the case, OJB seems to cache objects on its own accord.

correct.


Is there some documentation telling me how I can gain control of the cache, since e.g. I might not want to cache all types of objects etc ? Do I have to explictly remove objects I don't want to be cached?

http://db.apache.org/ojb/objectcache.html contains a basic introduction (but
is a bit outdated).

The typical solution to provide special caching behaviour is to implement a
new cache and to tell OJB to use this cache in OJB.properties. The cache
package contains several different caches that may be a starting point for
your ideas.

cheers,
Thomas


Thanks for any hints,

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to