#242 documentModel::getDocumentList()의 ‘documentList’ object cache 제거.

This commit is contained in:
bnu 2013-12-31 20:51:20 +09:00
parent 33db463615
commit 2149ed7700
3 changed files with 1 additions and 25 deletions

View file

@ -200,7 +200,6 @@ class documentAdminController extends document
$cache_key_item = 'object_document_item:'.$document_srl; $cache_key_item = 'object_document_item:'.$document_srl;
$oCacheHandler->delete($cache_key_item); $oCacheHandler->delete($cache_key_item);
} }
$oCacheHandler->invalidateGroupKey('documentList');
} }
return new Object(); return new Object();
} }
@ -461,7 +460,6 @@ class documentAdminController extends document
$oCacheHandler->invalidateGroupKey('commentList_' . $document_srl); $oCacheHandler->invalidateGroupKey('commentList_' . $document_srl);
} }
} }
$oCacheHandler->invalidateGroupKey('documentList');
} }
return $output; return $output;
} }

View file

@ -326,7 +326,6 @@ class documentController extends document
{ {
$cache_key = 'object:'.$obj->document_srl; $cache_key = 'object:'.$obj->document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
$oCacheHandler->invalidateGroupKey('documentList');
} }
return $output; return $output;
@ -541,7 +540,6 @@ class documentController extends document
{ {
$cache_key = 'object:'.$obj->document_srl; $cache_key = 'object:'.$obj->document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
$oCacheHandler->invalidateGroupKey('documentList');
//remove document item from cache //remove document item from cache
$cache_key = 'object_document_item:'.$obj->document_srl; $cache_key = 'object_document_item:'.$obj->document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
@ -636,7 +634,6 @@ class documentController extends document
{ {
$cache_key = 'object:'.$document_srl; $cache_key = 'object:'.$document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
$oCacheHandler->invalidateGroupKey('documentList');
$cache_key = 'object_document_item:'.$document_srl; $cache_key = 'object_document_item:'.$document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
} }
@ -784,7 +781,6 @@ class documentController extends document
$oCacheHandler = &CacheHandler::getInstance('object'); $oCacheHandler = &CacheHandler::getInstance('object');
if($oCacheHandler->isSupport()) if($oCacheHandler->isSupport())
{ {
$oCacheHandler->invalidateGroupKey('documentList');
} }
return $output; return $output;
@ -830,7 +826,6 @@ class documentController extends document
{ {
$cache_key = 'object:'.$document_srl; $cache_key = 'object:'.$document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
$oCacheHandler->invalidateGroupKey('documentList');
//remove document item from cache //remove document item from cache
$cache_key = 'object_document_item:'.$document_srl; $cache_key = 'object_document_item:'.$document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
@ -1225,7 +1220,6 @@ class documentController extends document
{ {
$cache_key = 'object:'.$document_srl; $cache_key = 'object:'.$document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);
$oCacheHandler->invalidateGroupKey('documentList');
//remove document item from cache //remove document item from cache
$cache_key = 'object_document_item:'.$document_srl; $cache_key = 'object_document_item:'.$document_srl;
$oCacheHandler->delete($cache_key); $oCacheHandler->delete($cache_key);

View file

@ -221,20 +221,6 @@ class documentModel extends document
$obj->sort_index = $sort_check->sort_index; $obj->sort_index = $sort_check->sort_index;
$obj->isExtraVars = $sort_check->isExtraVars; $obj->isExtraVars = $sort_check->isExtraVars;
// cache controll
$oCacheHandler = &CacheHandler::getInstance('object');
if($oCacheHandler->isSupport())
{
$object_key = 'object:'.$obj->module_srl.'_category_srl:'.$obj->category_srl.'_list_count:'.$obj->list_count.'_search_target:'.$obj->search_target.'_search_keyword:'.$obj->search_keyword.'_page'.$obj->page.'_sort_index:'.$obj->sort_index.'_order_type:'.$obj->order_type;
$cache_key = $oCacheHandler->getGroupKey('documentList', $object_key);
$output = $oCacheHandler->get($cache_key);
if($output)
{
return $output;
}
}
$this->_setSearchOption($obj, $args, $query_id, $use_division); $this->_setSearchOption($obj, $args, $query_id, $use_division);
if ($sort_check->isExtraVars) if ($sort_check->isExtraVars)
@ -313,7 +299,7 @@ class documentModel extends document
} }
$output->data[$virtual_number] = $GLOBALS['XE_DOCUMENT_LIST'][$document_srl]; $output->data[$virtual_number] = $GLOBALS['XE_DOCUMENT_LIST'][$document_srl];
$virtual_number --; $virtual_number--;
} }
if($load_extra_vars) $this->setToAllDocumentExtraVars(); if($load_extra_vars) $this->setToAllDocumentExtraVars();
@ -325,8 +311,6 @@ class documentModel extends document
$output->data[$number] = $GLOBALS['XE_DOCUMENT_LIST'][$document->document_srl]; $output->data[$number] = $GLOBALS['XE_DOCUMENT_LIST'][$document->document_srl];
} }
} }
//insert in cache
if($oCacheHandler->isSupport()) $oCacheHandler->put($cache_key,$output);
return $output; return $output;
} }