Task #56110

Epic #55070: Workpackages

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

IconUtility::getSpriteIcon() needs a cache

Added by Michiel Roos over 1 year ago. Updated over 1 year ago.

Status:Resolved Start date:2014-02-19
Priority:Should have Due date:
Assigned To:- % Done:

100%

Category:- Spent time: -
Target version:6.2.0
TYPO3 Version:6.2 Complexity:no-brainer
PHP Version:5.3 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 Core - Bug #56725: Improve mocking in IconUtilityTest Resolved 2014-03-10

Associated revisions

Revision 32481f5f
Added by Michiel Roos over 1 year 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
Added by Christian Kuhn over 1 year 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 1 year 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 1 year ago

  • Parent task set to #55065

#4 Updated by Gerrit Code Review over 1 year 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 1 year 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 1 year 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 1 year 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 1 year 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 1 year 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 1 year ago

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

Also available in: Atom PDF