Comment 1 for bug 1194811

Revision history for this message
Hanno Schlichting (hannosch) wrote :

When we introduced this cache, it was based on benchmarking against small and large sites. As the request itself is short-lived the memory is just used for a short period of time.

This is the same sort of request cache that's often found in Plone via plone.memoize. The main difference is that plone.memoize makes the assumption that the request object is annotatable (in the zope.annotation sense) and thus stores its cached values in annotations. Zope itself doesn't make this assumption, so direct Zope code cannot use this approach. Storing cached values in request.other was therefor the least invasive approach.

Unless someone can produce benchmarks which show an adverse effect of this cache, I'd consider the current approach to be reasonable.