[ADDED] New memcache option for contrib caches

This commit is contained in:
Sebastian Grewe 2014-02-12 08:07:58 +01:00
parent cb4211a618
commit 975b41276d
2 changed files with 5 additions and 1 deletions

View File

@ -671,8 +671,11 @@ class Statistics extends Base {
}
}
// No cached data, fallback to SQL ONLY if we don't use memcache
if ($this->config['memcache']['enabled'])
if ($this->config['memcache']['enabled'] && $this->config['memcache']['force']['contrib_shares']) {
// Do not use SQL queries and a second layer of caching
$this->debug->append('Skipping SQL queries due to config option', 4);
return false;
}
$stmt = $this->mysqli->prepare("
SELECT
a.username AS account,

View File

@ -222,6 +222,7 @@ $config['memcache']['port'] = 11211;
$config['memcache']['keyprefix'] = 'mpos_';
$config['memcache']['expiration'] = 90;
$config['memcache']['splay'] = 15;
$config['memcache']['force']['contrib_shares'] = false;
/**
* Cookies