forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thorsten Scherler <thors...@apache.org>
Subject Re: Locationmap caching initial cut
Date Tue, 08 Nov 2005 11:13:48 GMT
El lun, 07-11-2005 a las 20:45 +0000, Ross Gardler escribió:
> Tim Williams wrote:
> > I committed the first cut at locationmap caching.  It works at the
> > module level as opposed to an individual locationmap level.  
> 
> Cool stuff Tim, it's such a pleasure to create issues and see someone 
> fix them :-) I *really* appreciate it (as I am sure others do).
> 

+ 1 Mio.

> > Since the
> > improvements aren't that impressive, 
> 
> The figures you quote are reasonable, a saving of around 30-40 seconds 
> on a build time of around 3 minutes is pretty good. There is only really 
> the stuff for resolving skin (or views) related stuff and stylesheets 
> that will benefit from this since pages are typically only requested 
> once (unless in a dynamic environment). With the increased usage of such 
> resources in the views work your work will, most likely, show even more 
> improvement
> 

:) Yeah it is now after your commit, Tim, heaps faster. I did not stop
the time before my update but since views is 100% based on lm lookups I
can tell you the 30-40 seconds are in views much more. I think it gave
us a 50% boost. :)

> I have a site that takes 45 minutes to build, you improvements will make 
> quite a difference there (yes, it's very big, with lots of lm stuff).
> 
> Also if a site is hosted dynamically with pages requested frequently, 
> this caching will improve response times for those sites (I guess).
> 
> > I'm wondering if someone can give
> > me a better indication as to why the lm is slowing things up -- I'm
> > not sure if that's guessing or whether there is some test to determine
> > exactly where it's slowing up.
> 
> I originally created the issue as a "gut instinct" improvement. Not any 
> real evaluation of what is going on. I should have made that clearer in 
> the issue description, sorry.
> 
> If you turn on logging for the locationmap, you will see that either:
> 
> a) the logging statements are awful (quite possible as I threw many in 
> for debugging purposes), or
> b) there is lots of unnecessary duplication in the resolving of lm: URLs
> 
> Basically, there appears to be many duplicate log statements.
> 
> It's probably worth us evaluating the exact call sequence of events for 
> some typical requests.
> 

Maybe we can store the lastModified date in a hashmap of the lm for the
lookups then we can use this to see whether the entry has changed. On
the end we to enable lastModified in forrest core as well for static
site generation, to only publish sites that have really changed. Maybe
we can do this via the lm.

> > 
> > Here's what 3 runs each of the site-author did:
> > 
> > Without LM Caching
> > ------------------
> > 1 - 3:15
> > 2 - 3:17
> > 3 - 3:17
> > 
> > With LM Caching
> > ------------------
> > 1 - 2:48
> > 2 - 2:39
> > 3 - 2:39
> > 
> > Not exactly a news-making improvement...
> 
> Well worth the effort I think.
> 
> Thanks again.
> 
> Ross


Yeah, many thanks Tim. Good work.

salu2
-- 
thorsten

"Together we stand, divided we fall!" 
Hey you (Pink Floyd)


Mime
View raw message