Task #56110

Epic #55070: Workpackages

Epic #55065: WP: Overall System Performance (Backend and Frontend)

IconUtility::getSpriteIcon() needs a cache

Added by Michiel Roos over 5 years ago. Updated almost 2 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
Start date:
2014-02-19
Due date:
% Done:

100%

TYPO3 Version:
6.2
PHP Version:
5.3
Tags:
Complexity:
no-brainer
Sprint Focus:

Description

IconUtility::getSpriteIcon() is used heavily in many parts of the backend Treeview, page and list to name a few areas.

Most of the calls (279) use just the first parameter: $iconName

Many callers (135) use more parameters.

The calls with just the one parameter can be cached, preventing rendering the same code over and over again (in list mode and page tree for example).


Related issues

Related to TYPO3 Core - Bug #56725: Improve mocking in IconUtilityTest Closed 2014-03-10

Associated revisions

Revision 32481f5f (diff)
Added by Michiel Roos over 5 years ago

[TASK] Add cache to IconUtility::getSpriteIcon()

Cache calls to getSpriteIcon() that only use the first parameter.

Change-Id: I63e7dbaf81473b733a73f4a964e419dae0650f5f
Resolves: #56110
Releases: 6.2
Reviewed-on: https://review.typo3.org/27713
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters

Revision d413b2f6 (diff)
Added by Christian Kuhn over 5 years ago

[BUGFIX] Tests: Improve mocking in IconUtilityTest

The IconUtility tests depend on initialized $GLOBALS['TBE_STYLES']
and sometimes on initialized $GLOBALS['TCA']. This dependency is
removed by properly setting up needed arrays now, this also makes
the tests more obvious and easier to understand.
Additionally, the static cache property introduced with #56110 now
uses late static binding, enabling the tests to extend the class
and route any static cache changes to an test internal overlay
class to not pollute the static property of the base class.

Change-Id: I01166058da051a26d7aa2df315858468828ed346
Resolves: #56725
Related: #51436
Related: #56110
Releases: 6.2
Reviewed-on: https://review.typo3.org/28220
Reviewed-by: Anja Leichsenring
Tested-by: Anja Leichsenring
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters

History

#2 Updated by Gerrit Code Review over 5 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#3 Updated by Ingo Schmitt over 5 years ago

  • Parent task set to #55065

#4 Updated by Gerrit Code Review over 5 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#5 Updated by Gerrit Code Review over 5 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#6 Updated by Gerrit Code Review over 5 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#7 Updated by Gerrit Code Review over 5 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#8 Updated by Gerrit Code Review over 5 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#9 Updated by Gerrit Code Review over 5 years ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27713

#10 Updated by Michiel Roos over 5 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#11 Updated by Riccardo De Contardi almost 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF