[Zope] Programmatically flushing entries from RAM cache?

John Barham jbarham at gmail.com
Wed Dec 14 21:45:51 EST 2005


Is it possible to flush a path w/ a specific argument from a RAM cache
from a Python script?

Here's my situation:  I have a script FolderExists() that takes a
single "path" argument and, after running an SQL query, returns True
or False if the folder path exists or not in the database.  Since the
database query is relatively expensive, I want to cache its result in
RAM.  However, if a folder is created (using another Python script in
the same Zope instance) I want to flush the cached result for the path
(i.e., I don't want to flush all of the cached entries for the
FolderExists method if that can be avoided).

TIA,

  John


More information about the Zope mailing list