[ic] caching search results, academic discussion

Mike Heins interchange-users@icdevgroup.org
Thu Jan 30 23:44:01 2003


Quoting Mike Heins (mike@perusion.com):
> Quoting Jeff Dafoe (jeff@badtz-maru.com):
> > Hello,
> > 
> >     I have noticed that, on my system, most of the load is generated by
> > product scans.  It seems to be the IO issue created when dozens of people
> > hit the first page of the search results at once and the system has to scan
> > the products and write the resultant match list out to the session
> > directory.  I suspect it is the writing of the results that creates the
> > highest load, as write operations are typically much slower than read
> > operations.  When pondering this, I realized that all of my users are doing
> > the same searches (via the category_vertical links) but each search is
> > resulting in redundant scans and writes.  I think there may be some
> > opportunity for caching here.  I am thinking it might be possible to create
> > one copy of the results that were returned for a given search instead of
> > each user having their own copy.  This global result list could be updated
> > at certain intervals, much like the timed-build tag.
> >     This is assuming I haven't missed some way to cache results page that
> > currently exists, which is not impossible.
> 
> [timed-build ...] with an embedded search-region would be the way to
> go.
> 

[timed-build file="timed/cat.[cgi name=cat filter=filesafe keep=1]" minutes=60]

You need the keep=1 to prevent transforming the variable....
-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.513.523.7621      <mike@perusion.com>

Nature, to be commanded, must be obeyed. -- Francis Bacon