----- Original Message -----
Sent: Tuesday, March 09, 2004 11:05
PM
Subject: AW: caching of generated
xsp
hi
jakob,
the
reason for this is the current 'suboptimal' ;-) implementation of
SitemapSource (which represents resources accessed via the cocoon: protocol);
for getLastModified() it always returns 0, i.e. 'dunno'. furthermore the
SitemapSource is reset() after access via e.g. getInputStream() or toSAX(),
which hinders cachability.
anyways, there is a patch in bugzilla (named something like 'improved
SitemapSource') which resolves this and which you might want to try
out.
I use generated XSP in my setup, which is
working fine using the following sitemap code:
<map:match
pattern="page-*.xsp">
<map:generate src=""
type="serverpages"/>
<map:transform
src=""/>
<map:serialize
type="xml"/>
</map:match>
<map:match
pattern="page-*">
<map:generate
src="" type="serverpages"/>
<map:transform
src=""/>
<map:serialize
type="html"/>
</map:match>
this is all working very well, does however
generate and compile a
new xsp everytime a new request is
made.
If the source was a file resource instead of a
'cocoon:/' source I take
that the xsp only gets compiled when the date
of the source file is
newer than an existing compiled version.
How can control the 'modified' date for a
cocoon resource?
thanks,
Jakob