Bug #59824

Better index for determineSiteRoot

Added by Stefan Froemken over 5 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Should have
Category:
Database API (Doctrine DBAL)
Target version:
Start date:
2014-06-23
Due date:
% Done:

100%

TYPO3 Version:
6.2
PHP Version:
5.4
Tags:
Complexity:
easy
Is Regression:
No
Sprint Focus:

Description

Hello Core-Team,

updating the index determineSiteRoot is a little bit faster:

|       13 | 0.00025900 | SELECT uid FROM pages WHERE deleted=0 AND hidden=0 AND is_siteroot=1 LIMIT 1
|       14 | 0.00022800 | SELECT uid FROM pages WHERE deleted=0 AND hidden=0 AND is_siteroot=1 LIMIT 1

Stefan


Related issues

Related to TYPO3 Core - Bug #59809: Create better indexes for EM Closed 2014-06-23
Related to TYPO3 Core - Bug #55180: Increase Determination of siteroot page Closed 2014-01-20

Associated revisions

Revision bb535c6f (diff)
Added by Stefan Froemken almost 5 years ago

[BUGFIX] Bad index for determineSiteRoot

Extbase in the backend fires a query to the pages table where
deleted=0 AND hidden=0 AND is_siteroot=1 ORDER BY sorting LIMIT 1

The patch changes an index that was added for this query to
reduce the result more quickly, with the assumption there is only a
very small number of is_siteroot=1 pages in comparison to deleted
and hidden pages. Also hidden and deleted are not any longer part
of the index, since order by sorting with limit 1 will break the
rest of the result set very early.

Target of the patch is master only since the 6.2 variant is not
that bad, so there is no urgend need to force people changing
indexes in 6.2 production systems.

Resolves: #59824
Releases: master
Change-Id: I597516efb7704d929ee869cdaa39cd069421ed4f
Reviewed-on: http://review.typo3.org/31082
Reviewed-by: Christian Kuhn <>
Tested-by: Christian Kuhn <>
Reviewed-by: Mathias Schreiber <>
Tested-by: Mathias Schreiber <>
Reviewed-by: Anja Leichsenring <>
Tested-by: Anja Leichsenring <>

History

#1 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/31082

#2 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/31082

#3 Updated by Gerrit Code Review almost 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 http://review.typo3.org/31082

#4 Updated by Gerrit Code Review almost 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 http://review.typo3.org/31082

#5 Updated by Stefan Froemken almost 5 years ago

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

#6 Updated by Benni Mack about 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF