Search code examples
apachecachingaemdispatcher

How to find out what does dispatcher cache?


According this link

Dispatcher is Adobe Experience Manager's caching and/or load balancing tool.

I need to know what does my dispatcher cache.
How can I found out it?


Solution

  • The Adobe AEM/CQ5 dispatcher simply takes the response body from requests made into the CQ5 instances and saves them as files that then the httpd can deliver. The dispatcher can be configured to allow requests to be either cached or sent directly to the CQ5 instance. This configuration is done in a file dispatcher.any. Check the documentation, it is good enough.

    In general you decide what is cached and what not by defining a set of rules. "allow" means to cache and "deny" not to cache. For example:

    /rules
    {
      /0000  { /glob "*" /type "allow" }
      /0001  { /glob "/en/news/*" /type "deny" }
      /0002  { /glob "*/private/*" /type "deny"  }   
     }
    

    Will:

    • by default cache every request (rule 0000)
    • send to the instance requests to that contain "/en/news/" and "/private/*" (rules 0001 and 0002).

    The documentation also describe how to write these rules.

    Finally, the dispatcher will never cache requests without extension, requests with a query string, non-GET requests and requests with an authentication header.