Decrease sitemap size to 25,000 objects
authorjoshuaruesweg <ruesweg@woltlab.com>
Fri, 23 Jul 2021 17:45:26 +0000 (19:45 +0200)
committerjoshuaruesweg <ruesweg@woltlab.com>
Fri, 23 Jul 2021 17:45:26 +0000 (19:45 +0200)
Google allows up to 50,000 items in a single sitemap. This makes these sitemaps potentially very large. Even though Google allows up to 50 MB, too large sitemaps are still problematic, especially when it comes to troubleshooting in Google Webmaster Tools. Therefore, we minimise the limit of objects in a sitemap to 25,000 objects. This does not have any negative effects for Google as long as no more than 50,000 sitemaps are linked in the index sitemap.

wcfsetup/install/files/lib/system/worker/SitemapRebuildWorker.class.php

index 92e21d2bb30ec235bf75e0e2a18063c78bf9e371..9132d17a896cc9f45890847470f00513840fa7d2 100755 (executable)
@@ -32,7 +32,7 @@ class SitemapRebuildWorker extends AbstractRebuildDataWorker
     /**
      * The limit of objects in one sitemap file.
      */
-    const SITEMAP_OBJECT_LIMIT = 50000;
+    const SITEMAP_OBJECT_LIMIT = 25000;
 
     /**
      * Prefix for stored data in the registry.