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

Changeset 13139 for OpenPNE


Ignore:
Timestamp:
Nov 13, 2009, 7:02:06 PM (13 years ago)
Author:
nagasawa
Message:

#4332:マイフレンド最新blogの表示にfunction cacheを使用するように修正

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

Legend:

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

    r10769 r13139  
    9191function db_bookmark_blog_list($c_member_id, $limit)
    9292{
     93    static $is_recurred = false;  //再帰処理中かどうかの判定フラグ
     94
     95    if (!$is_recurred) {  //function cacheのために再帰処理を行う
     96        $is_recurred = true;
     97        $funcargs = func_get_args();
     98        $result = pne_cache_recursive_call(OPENPNE_FUNCTION_CACHE_LIFETIME_FAST, __FUNCTION__, $funcargs);
     99        $is_recurred = false;
     100        return $result;
     101    }
     102
    93103    $bookmarks = db_bookmark_c_member_id_list($c_member_id, true);
    94104    if (!$bookmarks) {
  • OpenPNE/trunk/webapp/lib/db/rss.php

    r6631 r13139  
    3030function db_rss_list_friend_c_rss_cache_list($c_member_id, $limit)
    3131{
     32    static $is_recurred = false;  //再帰処理中かどうかの判定フラグ
     33
     34    if (!$is_recurred) {  //function cacheのために再帰処理を行う
     35        $is_recurred = true;
     36        $funcargs = func_get_args();
     37        $result = pne_cache_recursive_call(OPENPNE_FUNCTION_CACHE_LIFETIME_FAST, __FUNCTION__, $funcargs);
     38        $is_recurred = false;
     39        return $result;
     40    }
     41
    3242    $friends = db_friend_c_member_id_list($c_member_id, true);
    3343    if (!$friends) {
  • OpenPNE/trunk/webapp/lib/util/cache.php

    r8659 r13139  
    8484    pne_cache_drop('db_friend_c_friend_list_random4c_member_id', $c_member_id, 5);
    8585    pne_cache_drop('p_h_home_c_diary_friend_list4c_member_id', $c_member_id, 5);  //最新日記フィード
     86    pne_cache_drop('db_rss_list_friend_c_rss_cache_list', $c_member_id, 5);
     87    pne_cache_drop('db_rss_list_friend_c_rss_cache_list', $c_member_id, 20);
    8688    $c_member_id = (string)$c_member_id;
    8789    pne_cache_drop('db_friend_c_friend_id_list4c_member_id', $c_member_id, 9);  //フレンドリスト
    8890    pne_cache_drop('db_friend_c_friend_list_random4c_member_id', $c_member_id, 5);
    8991    pne_cache_drop('p_h_home_c_diary_friend_list4c_member_id', $c_member_id, 5);  //最新日記フィード
     92    pne_cache_drop('db_rss_list_friend_c_rss_cache_list', $c_member_id, 5);
     93    pne_cache_drop('db_rss_list_friend_c_rss_cache_list', $c_member_id, 20);
    9094
    9195    //誕生日フィード
     
    232236    $c_member_id = (int)$c_member_id;
    233237    pne_cache_drop('db_bookmark_member_list', $c_member_id, 9);
     238    pne_cache_drop('db_bookmark_blog_list', $c_member_id, 5);
     239    pne_cache_drop('db_bookmark_blog_list', $c_member_id, 10);
    234240    $c_member_id = (string)$c_member_id;
    235241    pne_cache_drop('db_bookmark_member_list', $c_member_id, 9);
     242    pne_cache_drop('db_bookmark_blog_list', $c_member_id, 5);
     243    pne_cache_drop('db_bookmark_blog_list', $c_member_id, 10);
    236244}
    237245
Note: See TracChangeset for help on using the changeset viewer.