Created on 23 January 2021, almost 4 years ago
Updated 4 December 2023, about 1 year ago

Problem/Motivation

I have a memory limit error when I generate a sitemap of about 30,000 content .
A sitemap is supposed to handle up to 50,000 links

Steps to reproduce

Select sitemap entites ( content, taxo, menu_links) == ~30 000 links -- then click on generate.
After few minutes you'll get ajax error, memory limit.

Proposed resolution

Unset variables in batch operations, to free memory.
Memory usage is not expected to increase with batch processing

πŸ› Bug report
Status

Needs review

Version

1.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡¦Ukraine ankondrat4 Lutsk

    Hello.

    Thank you @jansete for patch. It works for me, if I set up separate sitemaps to parts by 1000 links as from UI as from terminal by drush command.
    I have tested on site with more 150000 nodes and more 100 languages.
    I think this patch need to add in contrib module xmlsitemap.

  • πŸ‡¨πŸ‡¦Canada JayDarnell Guelph, Ontario

    Tested with Drupal 10.1.6, PHP 8.1.21 and 8.x-1.5 and the patch from #5. Unfortunately my initial sitemap.xml generation still failed. The only way I could get it to complete is if I manually bump my memory limit with ini_set('memory_limit', '2G') But this worked even without the patch.

Production build 0.71.5 2024