Project

General

Profile

Actions

Task #99157

open

Performance optimize sitemap.xml generation

Added by Sybille Peters over 1 year ago. Updated 10 months ago.

Status:
Under Review
Priority:
Should have
Assignee:
-
Category:
SEO
Target version:
-
Start date:
2022-11-21
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
12
PHP Version:
Tags:
performance, sitemap, large-site
Complexity:
Sprint Focus:

Description

Loading sitemap.xml seemed slow, had load time of more than 20s (see measurements below of over a minute).

- the cache duration (seo_sitemap.config.cache_period) for sitemaps is by default 900 (15 minutes) which seems very short as the average page cache time is 24h. While having a fresh sitemap is of course prefereable. But, due to the long load time, this means the sitemap is effectively broken on large sites, until it is warmed up again. (the cache duration can of course be overridden but it remains the default)
- There is an SQL fetch with select * (all fields) . It is probably not necessary to fetch all the fields.

SELECT * FROM `pages` WHERE (`uid` IN (57119 ...)) AND (no_index = 0) AND (`doktype` NOT IN (3, 4, 6, 7, 199, 254, 255)) AND ((`pages`.`deleted` = 0) AND (`pages`.`hidden` = 0) AND (`pages`.`starttime` <= 1669052220) AND ((`pages`.`endtime` = 0) OR (`pages`.`endtime` > 1669052220))) ORDER BY `uid` ASC

This alone does not contribute to the long load time, but it might be possible to make some of the SQL queries more efficient.

System

- TYPO3 11.5.19
- pages in sitemap (default language): ~25000
- also news in sitemap (default language): ~15000

Measurements

Feching the individual sitemaps for translated pages seems especially slow.

After a full cache flush:

(default language is German, English is translation)

DB queries

SELECT * FROM `pages` WHERE (`uid` IN (57119 ...)) AND (no_index = 0) AND (`doktype` NOT IN (3, 4, 6, 7, 199, 254, 255)) AND ((`pages`.`deleted` = 0) AND (`pages`.`hidden` = 0) AND (`pages`.`starttime` <= 1669052220) AND ((`pages`.`endtime` = 0) OR (`pages`.`endtime` > 1669052220))) ORDER BY `uid` ASC;


Related issues 1 (1 open0 closed)

Related to TYPO3 Core - Task #100100: Improve performance of PagesXmlSitemapDataProviderUnder Review2023-03-06

Actions
Actions #1

Updated by Christian Eßl about 1 year ago

  • Related to Task #100100: Improve performance of PagesXmlSitemapDataProvider added
Actions #2

Updated by Gerrit Code Review about 1 year ago

  • Status changed from New to Under Review

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

Actions #3

Updated by Gerrit Code Review about 1 year ago

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

Actions #4

Updated by Gerrit Code Review about 1 year ago

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

Actions #5

Updated by Gerrit Code Review about 1 year ago

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

Actions #6

Updated by Gerrit Code Review about 1 year ago

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

Actions #7

Updated by Gerrit Code Review about 1 year ago

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

Actions #8

Updated by Gerrit Code Review about 1 year ago

Patch set 8 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/78044

Actions #9

Updated by Gerrit Code Review about 1 year ago

Patch set 9 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/78044

Actions #10

Updated by Gerrit Code Review 12 months ago

Patch set 10 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/78044

Actions #11

Updated by Gerrit Code Review 10 months ago

Patch set 11 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/78044

Actions #12

Updated by Sybille Peters 10 months ago

  • Description updated (diff)
Actions #13

Updated by Sybille Peters 10 months ago

  • Description updated (diff)
Actions

Also available in: Atom PDF