[Zope] Script caching

Jamie Heilman jamie at audible.transient.net
Mon Oct 6 02:25:01 EDT 2003


CHRISTOPHER TIGNOR wrote:
> I need to cache the results from a parameterized python script that makes a
> parameterized database call for a long period of time (about a day) as the
> data doesn't change much.  I have associated the script w/ a ram_cache
> manager and cranked up the expiration time but don't to be getting the
> consistent behavior I was expecting.  The documentation in general for the
> zope caching seems pretty impoverished.  Anyone know how to do this?

Depends.  What kind of behavior did you expect and what kind of
behavior are you seeing?  You'll have to give us more information
about the requests and expected responses before we can really tell
you what the problem is.  Zope's caching documentation is somewhat
anemic, it helps a great deal if you skip its pretenses and simply go
directly to the source.  Of course if you don't know python that might
not be all that much more enlightening.  I will say this, RCMs are not
particularly flexible in-terms of what they use as a cache "key"
(think: dictionary key), and you might have better luck with something
that gives you more control (yes this is a thinly veiled plug for my
own cache manager).  But realy we need more data about what behavior
you're trying to elicit.

-- 
Jamie Heilman                     http://audible.transient.net/~jamie/
"Paranoia is a disease unto itself, and may I add, the person standing
 next to you may not be who they appear to be, so take precaution."
						-Sathington Willoughby



More information about the Zope mailing list