On Monday 04 February 2002 11:44, Robin Berjon wrote: > On Monday 04 February 2002 10:40, Matt Sergeant wrote: > > How about math:random from exlst? It should be supported natively by > > XML::LibXSLT (though I haven't tried it). > > > > <xsl:value-of xmlns:math="http://exslt.org/math" select="math:random() > > * 100000"/> > > This opens up a problem that I've been thinking of these past few days. > Normal stylesheets will not produce different results when called with the > same data. Some of the exslt extensions will however cause that to happen, > probably defeating the way the current cache works. > > How do we deal with this problem ?
Well, even in principle its not possible to BOTH cache something AND have it be different every time... Start with what you have to go on. There are some exslt functions which would have predictable effects on the output, just depending on their input. If everything was cached based on selectable attributes of the request, and any output stage of the pipeline could be cached then you could simply flag certain things as being significant to cache validity at that stage. Anything that you CANNOT predict from information available to AxKit you simply can't cache. In the case of a random number, you're sunk! Turn off caching. If its some other factor then I guess you could design a way to have a "cache valid hook" that would let someone do arbitrary tests to determine cache validity. I guess anyone that wants to write a cacheing module can do that already. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
