Caching.html 2.7 KB
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta name="generator" content=
    "HTML Tidy for Mac OS X (vers 31 October 2006 - Apple Inc. build 13), see www.w3.org" />
    <title>
      Caching -- /DesignIssues
    </title>
    <nextid />
  </head>
  <body bgcolor="#FFC060" text="#302005">
    <a href="OldDocs.html"><img src=
    "../Icons/WWW/arch1990.gif" /></a>
    <hr />
    <h1>
      Document caching
    </h1>Three operations in the retrieval of a document may take
    significant time:
    <ul>
      <li>
        <a name="3" href="Formats.html#4">Format conversion</a> by
        the server, including <a name="5" href=
        "Versioning.html#3">version regeneration</a>
      </li>
      <li>Data transmission across the network
      </li>
      <li>Format conversion by the browser
      </li>
    </ul>At each stage, the server (in the first case) or browser
    (in the other cases) may decide to keep a temporary copy of the
    result. This copy should ideally be common to many browsers.
    <p>
      Automatic caching relieves the user of having to explicitly
      save things which may be referred to again. It also relieves
      the system of keeping multiple copies (one for each user who
      has read the document). It allows local disk space to used
      optimally. Cache management takes into account such factors
      as
    </p>
    <ul>
      <li>
        <a name="2" href="#1">expiry date</a>
      </li>
      <li>file size
      </li>
      <li>time taken to get the file
      </li>
      <li>frequency of access
      </li>
      <li>time since access
      </li>
    </ul>
    <h2>
      <a name="1">Expiry date</a>
    </h2>As a guide to help a cache program optimise the data it
    caches, it is useful if a document is transmitted with an
    estimate by the server of the lengt of time the data may be
    kept for. This allows fast changing documents to be flushed
    from the system, preventing readers from being mislead. (I
    would not propose any notification of document changes to be
    distributed to cache managers automatically). For example, an
    RFC may be cached for years, while the state of the alarm
    system may be marked as valid for only one minute.
    <p>
      Window-oriented browsers effectively cache documents when
      they keep several at a time in memory, in different windows.
      In this case, for very volatile data, it may be useful to
      have the browser automatically refresh the window when its
      data expires.
    </p>
    <p>
      ( <a name="4" href="Overview.html">design issues</a>
      )_________________________________
    </p>
    <address>
      <a name="0" href="../../../WWW/disclaimer.html">Tim BL</a>
    </address>
  </body>
</html>