cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andy Lewis <Andy.Le...@NSMG.VERITAS.com>
Subject RE: Cache
Date Mon, 24 Jan 2000 20:41:30 GMT
I would not only like to see something accommodate that case, but go further
if possible, and even one of the resources used to produce the page have
change, avoid re-processing those that haven't changed. I realize that at
some point there are diminishing returns, but so far I've seen VERY
expensive processing at every step for many requests, so my gut feel says it
would be worth it.

Andy Lewis
eBusiness Development Manager
VERITAS Software, Heathrow, Florida
Voice:  407-531-7584  -  Fax:  407-531-7686  -  Cell:  407-718-4718
Pager:  4077184718@mobile.att.net  -  EMail:  andy.lewis@veritas.com
<mailto:andy.lewis@veritas.com> 

" Some days, it is best to keep reality at arms length..."


		-----Original Message-----
		From:	Pierpaolo Fumagalli [mailto:pier@apache.org]
		Sent:	Monday, January 24, 2000 3:31 PM
		To:	cocoon-dev@xml.apache.org
		Subject:	Re: Cache

		Hannes Haug wrote:
		> 
		> Pierpaolo Fumagalli wrote:
		> >
		> > I bet that for checking cache, proxies issue a HEAD
command instead of a
		> > GET or POST, if they can do it, and in case of HEAD
requests, we need to
		> > specify that the document wasn't changed.
		> 
		> It's a GET with a If-Modified-Since header or something
similar.

		I thought it was a HEAD. But no problems... If it's the same
thing, we
		don't have to send the content in both cases...

		> > There are three cases:
		> >
		> > 1) The document need to be generated (generate the whole
stuff)
		> > 2) The document is cached but not proxied (send content
in cache)
		> > 3) The document is cached and proxied (just reply that
it didn't change)
		> 
		> Why do we need 2) at all?

		Yes. Just consider this case: We have two clients: ClientA
and ClientB.
		They don't use proxies, or they use different ones, and it's
the first
		time that they, or theyr proxy servers, hit the
		"http://foo.bar/cocoon/generated/doc.xml" page.
		This page is simply an XML file with a stylesheet applied to
it (so we
		can check if the source XML or XSL have changed from the
last
		generation).
		ClientA hits "http://foo.bar/cocoon/generated/doc.xml" at
1200 hours
		exactly, Cocoon, for the first time, generates the page,
sends it to
		ClientA and stores it into its cache.
		ClientB hits the same url at 1201 hours, and, since it's the
first time
		he tries to get that url, he cannot provide a
If-Modified-Since header.
		If Cocoon has a cache, then he can see  that no changes were
made to the
		XML and to the XSL since 1200 hours, and serve the cached
content,
		while, if he doesn't, he HAS to regenerate the page. So, we
avoid one
		generation step :)

			Pier

		-- 
	
--------------------------------------------------------------------
		-          P              I              E              R
-
		stable structure erected over water to allow the docking of
seacraft
		<mailto:pier@betaversion.org>
<http://www.betaversion.org/~pier/>
	
--------------------------------------------------------------------
		- ApacheCON Y2K: Come to the official Apache developers
conference -
		-------------------- <http://www.apachecon.com>
--------------------

Mime
View raw message