+

Search Tips   |   Advanced Search

Configure Edge Side Include caching

The web server plug-in contains a built-in ESI processor that can cache whole pages, as well as fragments, providing a higher cache hit ratio. The cache implemented by the ESI processor is an in-memory cache, not a disk cache, therefore, the cache entries are not saved when the web server is restarted.

Edge Side Include (ESI) is configured through the plugin-cfg.xml file.

When a request is received by the web server plug-in, it is sent to the ESI processor, unless the ESI processor is disabled. It is disabled by default. If a cache miss occurs, a Surrogate-Capabilities header is added to the request and the request is forwarded to the WebSphere Application Server. If servlet caching is enabled in the application server, and the response is edge cacheable, the application server returns a Surrogate-Control header in response to the WAS plug-in.

The value of the Surrogate-Control response header contains the list of rules used by the ESI processor to generate the cache ID. The response is then stored in the ESI cache, using the cache ID as the key. For each ESI include tag in the body of the response, a new request is processed so that each nested include results in either a cache hit or another request that forwards to the application server. When all nested includes have been processed, the page is assembled and returned to the client.

The ESI processor is configurable through the WebSphere web server plug-in configuration file plugin-cfg.xml. The following is an example of the beginning of this file, which illustrates the ESI configuration options.


Tasks


Subtopics


  • Use the dynamic cache service
  • Task overview: Using the dynamic cache service to improve performance
  • Web server plug-in properties