[Twisted-web] html cache with timeout

Andrea Arcangeli andrea at cpushare.com
Wed Feb 2 12:03:47 MST 2005


On Wed, Feb 02, 2005 at 06:35:30PM +0000, Valentino Volonghi wrote:
> I think you can cache the result of self.docFactory.load() in the same way you put t.cached() in loader.stan()

I'd certainly need to cache the xml fragments.

I've code like this:

class xx_class(rend.Fragment):
	docFactory = loaders.xmlfile('xxx.xml', XMLDIR, ignoreDocType = True)

I'd need to cache the output of the above.

It's not exactly clear to me how to do that with the stan cache, could
you make an example (or if you already did it in weever let me know and
I'll have a look).

If I can use the stan cache for the above, then I can use it for the
rend.Page too, and I can benchmark if there's any difference.

thanks!



More information about the Twisted-web mailing list