WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #21112, comment 7


Ignore:
Timestamp:
12/14/2015 11:35:23 AM (6 years ago)
Author:
javorszky
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #21112, comment 7

    initial v1  
    1 Just to add a bit more emphasis on this: a library we're using creates posts to keep track of scheduled events (wp's cron is not good enough). By default the post_name is not populated, but even when it is, because WordPress would do it on ajax, there's no authenticated user, and the post is pending. `wp_insert_post` strips `post_name` even if one was passed through [here](https://core.trac.wordpress.org/browser/trunk/src/wp-includes/post.php#L3014).
     1Just to add a bit more emphasis on this: a library we're using creates posts to keep track of scheduled events (wp's cron is not good enough). By default the post_name is not populated, but even when it is, because WordPress would do it on ajax, there's no authenticated user, and the post is pending. `wp_insert_post` strips `post_name` even if one was passed through [https://core.trac.wordpress.org/browser/trunk/src/wp-includes/post.php#L3014 here].
    22
    33Because there's no way to bypass this, on a large site when there are 60,000+ entries with the same empty post_name, the server just comes to a grinding halt. It's also not great with hosts like WPEngine, that have a hard limit for script execution. It's 60 seconds in WPEngine's case.