-----BEGIN PGP SIGNED MESSAGE-----
Even though I am the perpetrator, I think the current way of caching,
using ZCacheable and RAM cache managers, is absolutely horrific. It's
cumbersome to set up and the ZCacheable API is ugly as sin using it
from code. I think simplification is needed.
I personally don't see any need to have caching in plugins
themselves. Instead, caching should be applied at the "gateway" into
the user folder, where it emits user objects. These user objects
should be cached as a whole. I am envisioning a thread-independent
cache (meaning no redundant lookups in each thread) that is
configured using a caching ZMI tab on the PAS instance. No more Cache
tab everywhere and no more RAM cache managers to configure. And no
more contortions in plugin code to utilize ZCacheable.
This model is the exact same model used in the LDAPUserFolder itself.
The caching mechanism in the LDAPUserFolder contains two thread-
independent "bags" where unwrapped users are stored: One exclusively
for user objects generated from "passwordless" lookups, such as calls
to getUser or getUserById and friends, and those generated by lookups
that provide passwords. In this particular application having two
user caches is simply an artifact of my slight abuse of getUser, so
it might end up different in PAS.
Who's got an opinion?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
-----END PGP SIGNATURE-----
Zope-PAS mailing list