mod_accessibility

Performance Considerations

mod_accessibility is designed to put a very minimal extra load on your server. It parses outgoing documents in a single pass, using the SAX API - the fastest and most efficient form of markup processing. mod_accessibility is also a pipelined filter: it can send the start of a document to the client before it has seen the end of it.

Cacheability

This is basically a similar situation to that of server-side includes (mod_ssi, usually used with .shtml files). In both cases, the biggest influence on performance is cacheability.

mod_ssi addresses this issue with a directive called XBitHack, that causes Apache to generate HTTP headers that permit cacheing. This distinguishes between static included content (which should be cached) and dynamic includes (which can't be cached if the contents will be different for each hit).

The situation with mod_accessibility is slightly different. There are no includes generating dynamic content, so when used for static HTML pages it makes them cacheable. However, there is an additional consideration: mod_accessibility can also be used with dynamic content that is inherently non-cacheable. It deals with this by making its output cacheable if and only if its input is cacheable. Or, more precisely, it simply doesn't touch the HTTP headers concerned with cacheing.

So in summary, the biggest influence on performance is whether your contents are cacheable, and mod_accessibility has absolutely no effect on it.

mod_cache

mod_cache serves to cache dynamic contents, to save the server having to regenerate them for every hit. This will have the biggest effect when generating the contents is expensive: for example, when it is dynamically generated by CGI, PHP or JSP, but may give savings on any document processed with mod_accessibility.

mod_cache is always safe with mod_accessibility. So in any situation where mod_cache can be used, it can also be used with mod_accessibility. Note that this includes the (trivial) case of static HTML pages, where you can use it although of course you normally wouldn't.

HTML Frames are a special case where mod_cache may offer substantial improvements as discussed below.

Included Contents

The other important consideration arises when mod_accessibility retrieves included contents by HTTP. There are two situations where this happens:

  1. When expanding Frames, the frame contents are retrieved. This is the most expensive operation performed by mod_accessibility. When using frames, mod_cache is likely yield substantial performance improvements.
  2. In Full mode, mod_accessibility will retrieve the Titles of documents linked. This is expensive, but mod_accessibility maintains its own cache of the results, so the performance hit is once-only.

Note that the HTTP functions used to retrieve remote contents are rather primitive, and subject to change in a future version.