Closed vwondra closed 8 years ago
I agree with your issue, but not conclusion though. Why would we invalidate for dynamic pages?.. From backtrace it's seems most likely that invalidation fires for new order being created.
Since orders are non-public CPT this shouldn't happen and was fixed in #4429, fix will be included in next point release. :)
No, wait, I am not sure that PR catches that specific case. Will test to be sure.
What did you expect to happen?
The checkout to go smoothly and be quick.
What happened instead?
The checkout is very slow and intermittently times out
How can we reproduce this behavior?
Watch your server error logs when trying to checkout with the Authorize.NET CIM WooCommerce gateway
Can you provide a link to a page which shows this issue?
https://readymaderesources.com/checkout/
Technical info
This took some time to track down. The site is hosted at FlyWheel (Getflywheel.com). We requested the error logs and in the slow error logs dated 5/11 and 5/12 you can see what I'm talking about.
It appears that the Yoast Sitemap is trying to clear the sitemap cache and add the dynamically generated WooCommer Checkout and thank you pages... and since they are dynamically generated it times out.
[11-May-2016 17:16:24]
script_filename = /www//index.php [0x00007f691c9ef108] mysqli_query() /www/wp-includes/wp-db.php:1811 [0x00007f691c9eec58] _do_query() /www/wp-includes/wp-db.php:1717 [0x00007f691c9edea8] query() /www/wp-content/plugins/wordpress-seo/inc/sitemaps/class-sitemaps-cache-validator.php:175 [0x00007f691c9ed9d0] cleanup_database() /www/wp-content/plugins/wordpress-seo/inc/sitemaps/class-sitemaps-cache-validator.php:131 [0x00007f691c9ed780] invalidate_storage() /www/wp-content/plugins/wordpress-seo/inc/sitemaps/class-sitemaps-cache.php:188 [0x00007f691c9ed560] clear() /www/wp-content/plugins/wordpress-seo/inc/sitemaps/class-sitemaps-cache.php:132 [0x00007f691c9ed420] invalidate() /www/wp-content/plugins/wordpress-seo/inc/sitemaps/class-sitemaps-cache.php:163 [0x00007fffdf33d8b0] invalidate_post() unknown:0 [0x00007f691c9ed228] call_user_func_array() /www/wp-includes/plugin.php:525 [0x00007f691c9ec4e0] do_action() /www/wp-includes/post.php:3529 [0x00007f691c9e8ff8] wp_insert_post() /www/wp-content/plugins/woocommerce/includes/wc-core-functions.php:99 [0x00007f691c9e8268] wc_create_order() /www/wp-content/plugins/woocommerce/includes/class-wc-checkout.php:208 [0x00007f691c9e5ba0] create_order() /www/wp-content/plugins/woocommerce/includes/class-wc-checkout.php:628 [0x00007f691c9e0638] process_checkout() /www/wp-content/plugins/woocommerce/includes/class-wc-ajax.php:450 [0x00007fffdf33e380] checkout() unknown:0 [0x00007f691c9e03c0] call_user_func_array() /www/wp-includes/plugin.php:525 [0x00007f691c9df9d0] do_action() /www/wp-content/plugins/woocommerce/includes/class-wc-ajax.php:82 [0x00007fffdf33e890] do_wc_ajax() unknown:0 [0x00007f691c9df638] call_user_func_array() /www/wp-includes/plugin.php:525 [0x00007f691c9dec78] do_action() /www/wp-includes/template-loader.php:12 . To fix this issue, we disabled the Yoast Sitemap functionality and replaced it with the Google XML Sitemaps. As soon as we did that the checkout process was fast and every test was successful.
20160513083903_ReadyMadeResources_logs.zip