This project is not covered by Drupal’s security advisory policy.

This module provides an alternative file to serve anonymous page requests from xCache. This module makes use of DRUPAL_BOOTSTRAP_EARLY_PAGE_CACHE and implements page_cache_fastpath().

For anonymous users I want to serve pages from XCache, but I didnt want to use memory caching as a replacement for every cache table, only serving cache_page content for anon users from XCache.

Some of the code and concept is inspired by Cache Router, Memcache and XCache however for most parts the code is something I wrote in collaboration with Nick Thompson

The concept

- set a cookie for logged in users (anon/auth flag)
- page_cache_fastpath() checks if cookie is not set
- if cookie is set(auth user): proceed as normal, standard drupal cache functions (no cache)

- if cookie is not set (anon):
-- check if cached page exists in XCache, if it does serve the page
-- if cache doesnt exist in xcache, check db, exists in DB? save it in XCache & serve page
-- page doesnt exist in XCache or DB? Generate page, cache it in DB and Xcache, serve page

This module does not use XCache for any other cache tables apart from cache_page for anonymous users. All other cache tables use standard functionality. Only the anonymous traffic will be affected.

If you want a complete cache replacement you can use Cache Router, Memcache etc.


- This module requires version 1.3.0 or higher of xcache Do not install if your xcache version is lower than 1.3.0

- add the following php code to site settings.php

$conf['cache_inc'] = './sites/mysite/modules/xcache_cachepage/';
$conf['page_cache_fastpath'] = TRUE;

- enable cookies

- enable the module

Project information

  • caution Minimally maintained
    Maintainers monitor issues, but fast responses are not guaranteed.
  • caution No further development
    No longer developed by its maintainers.
  • Module categories: Performance and Scalability
  • chart icon224 downloads
  • shield alertThis project is not covered by the security advisory policy.
    Use at your own risk! It may have publicly disclosed vulnerabilities.