Maypole::Cache - Flexible caching of Maypole request output


Maypole-Cache documentation  | view source Contained in the Maypole-Cache distribution.

Index


NAME

Top

Maypole::Cache - Flexible caching of Maypole request output

SYNOPSIS

Top

  package BeerDB;
  use base 'Apache::MVC';
  use Maypole::Cache;
  BeerDB->config->{cache_options} = {
    class => "Cache::FileCache",
    default_expires_in => 600,
    ...
  };

DESCRIPTION

Top

This module replaces Maypole's main handler in your application with one which uses Cache::Cache to cache request output. By default it uses Cache::SharedMemoryCache although this, and all other Cache::Cache options, can be changed using the cache_options configuration hash.

The module caches all pages, except those which trigger an authentication failure, or which use POST parameters, or when the nocache slot in the request object is set to a true value. A separate cache is maintained for each $r->user. You may want certain of your actions to set nocache if they do anything session-conditional.

SEE ALSO

Top

Maypole, Cache::Cache

AUTHOR

Top

Simon Cozens, <simon@cpan.org>

COPYRIGHT AND LICENSE

Top


Maypole-Cache documentation  | view source Contained in the Maypole-Cache distribution.