on the topic of cache freshness, one idea that I
thought was interesting was something IBM was
reportedly doing for the Olympics (or some other very
high-traffic) website.  Changes to the data in the
database triggered messages to the cache to invalidate
certain cached objects.  This removes then need to
check the freshness of the cached objects.

I'm guessing at how they achieved this, but I'd expect
they were using a trigger in db2 to send an MQ message
(its very simple using these products).  Obviously
this could be achieved with non-IBM components too.

--
jamie

--- "Chappell, Simon P" <[EMAIL PROTECTED]>
wrote:
> We have found that the biggest bang for the buck
> comes with pre-fetching data out of the database and
> building our business objects ahead of time and
> storing them in an in-memory cache. This means that
> we have a very large cache (we estimate at least a
> gig when we get fully ramped up for phase one and
> more after that), but we get phenominal throughput
> from it. Our reason for this was a maximum
> processing time of 3.6 seconds and we knew that we
> could not allow the database access to be the choke
> point in the system.
> 
> Concerning cache freshness, we confirm with a simple
> database query that the timestamp has not changed
> since we cached the data. This simple check takes
> less than 10ms, while the big multiple table joins
> to build our main object can total between a quarter
> and a half a second.
> 
> And of course we have database pooling active.
> 
> Hope this helps.
> 
> Simon
> 
>
-----------------------------------------------------------------
> Simon P. Chappell                    
> [EMAIL PROTECTED]
> Java Programming Specialist                     
> www.landsend.com
> Lands' End, Inc.                                  
> (608) 935-4526
> 
> 
> >-----Original Message-----
> >From: Jamie J [mailto:[EMAIL PROTECTED]]
> >Sent: Thursday, July 11, 2002 2:51 PM
> >To: [EMAIL PROTECTED]
> >Subject: where can caching help performance?
> >
> >
> >I'm wondering how people speed up their MVC
> webapps.
> >
> >Taglibs for caching parts of jsps seem like a good
> way
> >of improving the speed of a web app (see:
>
>http://jakarta.apache.org/taglibs/doc/cache-doc/intro.html,
> > http://www.opensymphony.com/oscache/tags.html, the
> >one that comes with weblogic etc).  
> >
> >e.g. (pseudo-tag):
> ><foo:cache timout="5mins">
> >
> ><!-- query the database and display details of the
> 10
> >most recent news items, or something -->
> >
> ></foo:cache>
> >
> >However they don't help much if you've got an MVC
> app,
> >because all your database access etc happens before
> >the view of it is rendered, as opposed to as it is
> >rendered  which is where these taglibs are useful. 
> 
> >
> >Is the only option with MVC to cache the data?  The
> >idea of caching the rendering of it too is
> appealing -
> >if they data hasn't changed, why keep re-rendering
> it?
> >(assuming everyone's view of it is the same).  It
> is
> >particularly appealing when you consider that it
> can
> >be done with no code changes - you can put a
> (servlet
> >2.3) filter in front of servlets/jsps you wanted
> >cached.
> >
> >Its portal-style applications that I'm thinking of
> >here, where you have discrete components of a page
> >which all may involve some database (or other
> >timeconsuming) activity, but the data doesn't
> change
> >often so the cached view of it can be updated every
> >X-minutes or so.
> >
> >What approaches do people use to speed up such
> apps? 
> >Is caching really only an option in the model,
> rather
> >than the view? (assuming its not the whole page
> you're
> >caching).
> >
> >--
> >jamie
> >
> >__________________________________________________
> >Do You Yahoo!?
> >Sign up for SBC Yahoo! Dial - First Month Free
> >http://sbc.yahoo.com
> >
> >--
> >To unsubscribe, e-mail:   
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> 
> 
> --
> To unsubscribe, e-mail:  
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> 


__________________________________________________
Do You Yahoo!?
Sign up for SBC Yahoo! Dial - First Month Free
http://sbc.yahoo.com

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to