I added a new method, expireCache, to the Database and DatabaseImpl classes.
The following is from the javadoc generated from this modification:
"public void expireCache(java.lang.Class[] type,
java.lang.Object[] identity)
throws PersistenceException
Expire objects from the cache. Objects expired from the cache will be read
from persistent storage, as opposed to being read from the performance
cache, during subsequent load/query operations. Objects may be expired from
the cache individually, using explicit type/identity pairs in the argument
list, or whole classes of objects may be expired by specifying a class type
without a corresponding entry in the identity array.
When objects are expired from the cache individually, by identity, objects
contained within a "master" object, for example objects maintained in a
one-to-many relationship, will automatically be expired from the cache,
without the need to explicitly identify them. This does not apply when
expiring objects by type. Each type, both container and contained objects
need to be specified."
Vince
-----Original Message-----
From: Martin, Margaret [mailto:[EMAIL PROTECTED]]
Sent: Monday, October 07, 2002 11:55 AM
To: [EMAIL PROTECTED]
Subject: Re: [castor-dev] Flushing the object cache
I believe that it supports flushing specific objects, classes of objects,
and the entire cache - but perhaps Vince could weigh in wiht a more
definitive answer -
Margaret
-----Original Message-----
From: Werner Guttmann [mailto:[EMAIL PROTECTED]]
Sent: Monday, October 07, 2002 11:42 AM
To: [EMAIL PROTECTED]
Subject: Re: [castor-dev] Flushing the object cache
At what level would this support flushing ? Flush the whole cache ? Or just
specific object instances ?
Werner
"Martin, Margaret" wrote:
> Boris,
> Take a look at the cache code that Vince Adamo posted some time back - it
> should adress this exact problem. As far as I know, the code has not been
> committed to the archives yet, but it is in use for several
implementations,
> so it is getting a workout -
>
> Hope this helps -
> Margaret
>
> -----Original Message-----
> From: Boris Klug [mailto:[EMAIL PROTECTED]]
> Sent: Monday, October 07, 2002 8:35 AM
> To: [EMAIL PROTECTED]
> Subject: [castor-dev] Flushing the object cache
>
> Hello!
>
> I am still fighting with the timestamp/caching issue, now will try to
store
> the timestamp in the db when I have time to do it.
>
> Another question would be: Is there a way to flush the object cache so
> Castor
> has to read in all (cached) objects when they are are used again?
>
> I store information about user/group/rights in the db and when the rights
> for
> one users are changed by the administrator, I want to have a menu item
> "Reread priviledges" for connected users. Now you have to way until the
> (time-limited) cache will expire.
>
> Thank you for your help!
>
> --
> Dipl. Inform. Boris Klug, control IT GmbH, Germany
>
> -----------------------------------------------------------
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
> unsubscribe castor-dev
>
> -----------------------------------------------------------
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
> unsubscribe castor-dev
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev