cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <blorit...@apache.org>
Subject Re: Adaptive Caching [was Re: initial checkin of the Scheme code]
Date Thu, 13 Dec 2001 15:42:54 GMT
Berin Loritsch wrote:

> Stefano Mazzocchi wrote:
> 
>> Talking about placing too many irons in the fire :)
>>
> 
> 
> Stefano, please forgive my ignorance, as I have an Associates Degree in
> Music Recording, and not a traditional CS degree.  I haven't had the
> higher math classes you and many others have had here.
> 
> I understand Algebra and Trigonometry ok, so if we can simplify these
> algorithms into a "pseudo-code" so I can wrap my head around them, I
> will be happy to jump in the discussion.  As it is now, It's going
> over my head.
> 
> I understand the Calculus ideas of functions (i.e. V(r,t)).  What throws
> me are the Sigmas (I studied Ancient Greek, so I know what the letters 
> are).
> I know they are meant to represent sums, or statistical data.  I don't know
> what the letter above the sigma or below the sigma is supposed to signify.
> 
> If you don't feel up to giving me a quick math lesson so I can grok the
> concepts fully, can you point me to a resource where I can teach myself?
> 
>> Thus, given
>>
>>  r        := resource
>>  t        := time of the request
>>  V(r,t)   := validity estimation cost
>>  P(r,t)   := production cost when caching is not performed
>>  Pc(r,t)  := production cost when caching is performed
>>  l(r,t)   := lookup cost
>>  s(r,t)   := storage cost
>>
>> and
>>
>>  I := sequence of invalid requests time [1,n]
>>  V := sequence of valid request time [1,m]


Also, I have to ask which aspects of the resource are we calculating?  Time
changed? size in bytes?

t = relative millis since begining of adaptation, time since last request, or absolute millis?

Also, what is the sample window that we have to look at.  It is impractical
to look at all samples for the life of the cache, so how many do we need to track?

It also helps to know the units in which these functions are measured, such as
Validity Estimation Cost (my assumption is time in millis).

Also not that storage and lookup costs can be reduced with asynchronous file IO.
It is not simple to program in those terms, but such a mechanism can speed up the
scalability of such operations.

You also have to consider the fact that an effective cache uses both memory and
file IO, so the storage costs between them vary greatly.



>> we have that
>>
>>                n
>>                --
>>  Invalid(r) =  \  (V(r,I ) + Pc(r,I ) + s(r,I ))
>>                /        i          i         i                --
>>               i = 1
>>
>> and
>>
>>              m
>>              --
>>  Valid(r) =  \  (V(r,I ) + L(r,I ))
>>              /        j         j
>>              --
>>            j = 1
>>
>> and
>>
>>             n                m
>>             --               --
>>  Ptot(r) =  \  P(r,I )   +   \  P(r,V )
>>             /       i        /       j
>>             --               --
>>           i = 1             j = 1



-- 

"They that give up essential liberty to obtain a little temporary safety
  deserve neither liberty nor safety."
                 - Benjamin Franklin


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message