Issue Bug Closed

#56657Caching framework specified in localconf.php is ignored by extbase

Michiel Roos 03/07/14, 16:07 updated 03/13/14, 11:20

Description

An attempt to override the cacheConfiguration for extbase as suggested in the wiki (http://wiki.typo3.org/Caching_framework) will fail:

$TYPO3_CONF_VARS['SYS']['caching']['cacheConfigurations']['cache_extbase_object']['backend'] = 't3lib_cache_backend_RedisBackend';
$TYPO3_CONF_VARS['SYS']['caching']['cacheConfigurations']['cache_extbase_object']['options'] = array();
$TYPO3_CONF_VARS['SYS']['caching']['cacheConfigurations']['cache_extbase_reflection']['backend'] = 't3lib_cache_backend_RedisBackend';
$TYPO3_CONF_VARS['SYS']['caching']['cacheConfigurations']['cache_extbase_reflection']['options'] = array();

The result is that the default Db backend will be used.

This is because extbase/ext_localconf.php has the following lines:

// use own cache tables
// Reflection cache:
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['cache_extbase_reflection'] = array(
    'frontend' => 't3lib_cache_frontend_VariableFrontend',
    'backend' => 't3lib_cache_backend_DbBackend',
    'options' => array(
        'cacheTable' => 'tx_extbase_cache_reflection',
        'tagsTable' => 'tx_extbase_cache_reflection_tags',
    ),
);
// Object container cache:
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['cache_extbase_object'] = array(
    'frontend' => 't3lib_cache_frontend_VariableFrontend',
    'backend' => 't3lib_cache_backend_DbBackend',
    'options' => array(
        'cacheTable' => 'tx_extbase_cache_object',
        'tagsTable' => 'tx_extbase_cache_object_tags',
    ),
);

This will overwrite any information specified in localconf.php

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.