View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002674 | OXID eShop (all versions) | 4.05. Performance | public | 2011-03-31 13:48 | 2012-12-10 13:29 |
Reporter | fanatique | Assigned To | |||
Priority | high | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 4.4.6 revision 32697 | ||||
Fixed in Version | 4.5.1 revision 38045 | ||||
Summary | 0002674: aList::getAttributes() is computed for each call | ||||
Description | aList::getAttributes() takes about 3 seconds per call in a shop with 300.000+ articles in one category and the value is not stored during a request. As the method is called more then once per request this leads to up to something like 7 seconds delay rendering an article list. It'd be good to at least store the value in some sort of registry over a request. Apart from that t might be a god idea to prefetch this and not commit it during the request itself. | ||||
Tags | Performance | ||||
Theme | Both | ||||
Browser | All | ||||
PHP Version | 5.3 | ||||
Database Version | 5.1 | ||||
|
@developers: check from source code side if such issue still exist |
|
Small module maybe useful for older versions: <?php class cached_alist extends cached_alist_parent{ public function getAttributes() { //implement caching if (!is_array($this->_aAttributes)){ if (!is_array($this->_aAttributes = parent::getAttributes())){ $this->_aAttributes = array(); } } return $this->_aAttributes; } } |
|
fixed, added an instance caching mechanism for the oxCategory::getAttributes() method. |