Changeset 3810
- Timestamp:
- Sep 2, 2007, 8:52:06 PM (14 years ago)
- Location:
- OpenPNE/branches/work/maruyama/prj_memacache_fc
- Files:
-
- 4 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
OpenPNE/branches/work/maruyama/prj_memacache_fc/config.php.sample
r3799 r3810 63 63 //有効にした場合は、最新情報の表示に遅延が起こることがあります 64 64 define('OPENPNE_USE_FUNCTION_CACHE', false); 65 66 // このオプションを有効にするためにはOPENPNE_USE_FUNCTION_CACHEをtrueにする必要があります。 67 // ファンクションキャッシュのキャッシュを保存するストレージにmemcacheを使用 68 define('OPENPNE_USE_FUNCTION_CACHE_MEMCACHE', false); 69 70 // OPENPNE_USE_FUNCTION_CACHE_MEMCACHEがtrueの場合の 71 // ファンクションキャッシュ用memcacheサーバ設定 72 $GLOBALS['_OPENPNE_MEMCACHE_LIST']['func_cache'] = array( 73 'dsn' => array( 74 'hostspec' => '127.0.0.1', 75 ), 76 ); 65 77 66 78 // MySQL ヒント使用設定 -
OpenPNE/branches/work/maruyama/prj_memacache_fc/webapp/lib/util/cache.php
r3075 r3810 9 9 static $instance; 10 10 if (empty($instance)) { 11 include_once 'Cache/Lite/Function.php'; 12 $options = array( 13 'cacheDir' => OPENPNE_VAR_DIR . '/function_cache/', 14 'hashedDirectoryLevel' => 2, 15 'hashedDirectoryUmask' => 0777, 16 ); 17 $instance = new Cache_Lite_Function($options); 11 if (OPENPNE_USE_FUNCTION_CACHE_MEMCACHE) { 12 include_once 'OpenPNE/Cache.php'; 13 $instance = new OpenPNE_Cache_Function('memcache', $GLOBALS['_OPENPNE_MEMCACHE_LIST']['func_cache']); 14 } else { 15 include_once 'Cache/Lite/Function.php'; 16 $options = array( 17 'cacheDir' => OPENPNE_VAR_DIR . '/function_cache/', 18 'hashedDirectoryLevel' => 2, 19 'hashedDirectoryUmask' => 0777, 20 ); 21 $instance = new Cache_Lite_Function($options); 22 } 18 23 } 19 24 return $instance;
Note: See TracChangeset
for help on using the changeset viewer.