ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Changeset 669


Ignore:
Timestamp:
Nov 10, 2006, 7:47:53 PM (14 years ago)
Author:
takanashi
Message:

携帯版ファンクションキャッシュの取り込み

Location:
OpenPNE/trunk/webapp/lib
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE/trunk/webapp/lib/db/commu.php

    r665 r669  
    5353function db_commu_c_commu4c_commu_id_k($c_commu_id)
    5454{
     55    static $is_recurred = false;  //再帰処理中かどうかの判定フラグ
     56
     57    if (!$is_recurred) {  //function cacheのために再帰処理を行う
     58        $is_recurred = true;
     59        $funcargs = func_get_args();
     60        return pne_cache_recursive_call(OPENPNE_FUNCTION_CACHE_LIFETIME_LONG, __FUNCTION__, $funcargs);
     61    }
     62
     63    $is_recurred = false;
     64
    5565    if ($c_commu = _db_c_commu4c_commu_id($c_commu_id)) {
    5666        $c_commu['count_member'] = _db_count_c_commu_member_list4c_commu_id($c_commu_id);
     
    10551065function db_commu_c_commu_list_lastupdate4c_member_id($c_member_id, $limit)
    10561066{
     1067    static $is_recurred = false;  //再帰処理中かどうかの判定フラグ
     1068
     1069    if (!$is_recurred) {  //function cacheのために再帰処理を行う
     1070        $is_recurred = true;
     1071        $funcargs = func_get_args();
     1072        return pne_cache_recursive_call(OPENPNE_FUNCTION_CACHE_LIFETIME_LONG, __FUNCTION__, $funcargs);
     1073    }
     1074
     1075    $is_recurred = false;
     1076
    10571077    $sql = 'SELECT DISTINCT c.* FROM c_commu_member AS cm, c_commu AS c' .
    10581078            ' WHERE cm.c_member_id = ? AND c.c_commu_id = cm.c_commu_id' .
     
    12641284function db_commu_c_commu_member_list_random4c_commu_id($c_commu_id, $limit)
    12651285{
     1286    static $is_recurred = false;  //再帰処理中かどうかの判定フラグ
     1287
     1288    if (!$is_recurred) {  //function cacheのために再帰処理を行う
     1289        $is_recurred = true;
     1290        $funcargs = func_get_args();
     1291        return pne_cache_recursive_call(OPENPNE_FUNCTION_CACHE_LIFETIME_LONG, __FUNCTION__, $funcargs);
     1292    }
     1293
     1294    $is_recurred = false;
     1295
    12661296    $sql = "SELECT cm.c_member_id, cm.nickname ";
    12671297    $sql .= "FROM c_member AS cm , c_commu_member AS ccm ";
  • OpenPNE/trunk/webapp/lib/db/friend.php

    r665 r669  
    448448function db_friend_c_friend_list_random4c_member_id($c_member_id, $limit)
    449449{
     450    static $is_recurred = false;  //再帰処理中かどうかの判定フラグ
     451
     452    if (!$is_recurred) {  //function cacheのために再帰処理を行う
     453        $is_recurred = true;
     454        $funcargs = func_get_args();
     455        return pne_cache_recursive_call(OPENPNE_FUNCTION_CACHE_LIFETIME_LONG, __FUNCTION__, $funcargs);
     456    }
     457
     458    $is_recurred = false;
     459
    450460    $sql = "SELECT cf.* , cm.nickname";
    451461    $sql .= " FROM c_friend AS cf, c_member AS cm";
  • OpenPNE/trunk/webapp/lib/util/cache.php

    r665 r669  
    7878{
    7979    pne_cache_drop('db_friend_c_friend_list4c_member_id', $c_member_id, 9);  //フレンドリスト
     80        pne_cache_drop('db_friend_c_friend_list_random4c_member_id', $c_member_id, 5);
    8081    pne_cache_drop('p_h_home_c_diary_friend_list4c_member_id', $c_member_id, 5);  //最新日記フィード
    8182
     
    99100function cache_drop_c_commu($c_commu_id)
    100101{
     102    pne_cache_drop('db_commu_c_commu4c_commu_id_k',$c_commu_id);
     103    pne_cache_drop('db_commu_c_commu_member_list_random4c_commu_id', $c_commu_id, 5);
    101104    pne_cache_drop('db_commu_c_commu_member_list4c_commu_id', $c_commu_id, 9);
    102105    pne_cache_drop('db_commu_c_commu4c_commu_id2', $c_commu_id);
     
    126129function cache_drop_c_commu_list4c_member_id($c_member_id)
    127130{
     131    pne_cache_drop('db_commu_c_commu_list_lastupdate4c_member_id', $c_member_id, 5);
    128132    pne_cache_drop('db_commu_c_commu_list4c_member_id_3', $c_member_id, 9);
    129133    pne_cache_drop('db_commu_c_commu_list4c_member_id_2', $c_member_id, 9);
Note: See TracChangeset for help on using the changeset viewer.