Re: Comment on ContainerCache?

[prev] [thread] [next] [Date index for 2004/07/16]

From: Perrin Harkins
Subject: Re: Comment on ContainerCache?
Date: 19:20 on 16 Jul 2004
On Fri, 2004-07-16 at 02:27, Heiko Klein wrote:
> Similar to LiveObjects, I would apply a ContainerCache per class/table. 
> When retrieving a object/row, it would first look in the CacheContainer 
> and only when it doesn't exists there, it would connect to the database 
> and put it into the ContainerCache.

You might want to look at the versions of this that have already been
written.  Check the mailing list archives for a couple of takes on
caching modules.

> The difference to LiveObjects is the lifetime of objects in the 
> ContainerCache, which would be much longer than in LiveObjects, i.e.
> a) as long as the low-watermark hasn't been reached, objects will live 
> forever
> b) above the high-watermark, all objects with refcount < 1 (not 
> currently referenced in the rest of the program) will be removed until 
> the low-watermark is reached

An object with refcount < 1 (i.e. 0) would already be gone from memory. 
Since you're talking about keeping things in memory, you probably mean
that you wouldn't use weak references, and this everything would have a
refcount of at least 1, so s/< 1/< 2/g.

- Perrin

Comment on ContainerCache?
Heiko Klein 06:27 on 16 Jul 2004

Re: Comment on ContainerCache?
Tim Bunce 09:42 on 16 Jul 2004

Re: Comment on ContainerCache?
Perrin Harkins 19:12 on 16 Jul 2004

Re: Comment on ContainerCache?
Yuval Kogman 14:10 on 16 Jul 2004

Re: Comment on ContainerCache?
Perrin Harkins 19:20 on 16 Jul 2004

Re: Comment on ContainerCache?
Heiko Klein 10:53 on 19 Jul 2004

Generated at 11:34 on 01 Dec 2004 by mariachi v0.52