[sldev] Proposition of cache improvment

Joshua Bell josh at lindenlab.com
Tue Apr 21 09:42:19 PDT 2009


Laurent Laborde wrote:
> 3) everytime something change in the sim, a new state uuid is
> generated and sim cache is discarded.

Here's another crazy idea that intrepid coders could play with - a two 
level cache, with per-region bucketing and reference counting. Assume 
the resident visits a limited number of regions very frequently, and 
assume that region contents change infrequently on the whole. Implement 
a cache bucket per region. Have items age out of the cache within 
buckets as infrequently as possible (and reference counted, so assets 
used in two regions are only purged if it ages out of both). Limit the 
number of region cache buckets - and possibly make that user-selectable 
(advanced option) - and weight those by time-spent-in-region.

In theory, the (say) 5 regions you hang out in frequently would "rez" 
instantly on teleport, and the (say) 5 sims you visit infrequently and 
irregularly wouldn't have that much of a different experience than you 
do today. Your least-frequently-visited region would need to stream down 
all content, but when you teleport back "home" everything looks ducky.

This would require no protocol or server-side changes (yay!).



More information about the SLDev mailing list