![wp_insert_post() sometimes takes awhile when creating pages programmatically. I'm guessing the function checks existing pages for collision on the slug? (Site has 700 pages). I'm looking to brainstorm ideas to speed it wp_insert_post() sometimes takes awhile when creating pages programmatically. I'm guessing the function checks existing pages for collision on the slug? (Site has 700 pages). I'm looking to brainstorm ideas to speed it](https://preview.redd.it/lv7td15rqnv21.png?auto=webp&s=f38f62316132e9e3e8cb06e7cbe0fbeb1447e172)
wp_insert_post() sometimes takes awhile when creating pages programmatically. I'm guessing the function checks existing pages for collision on the slug? (Site has 700 pages). I'm looking to brainstorm ideas to speed it
![WP All Import issues when option "Increase speed by disabling do_action calls in wp_insert_post during import" is enabled - WPML WP All Import issues when option "Increase speed by disabling do_action calls in wp_insert_post during import" is enabled - WPML](https://cdn.wpml.org/wp-content/uploads/2020/03/option.png)
WP All Import issues when option "Increase speed by disabling do_action calls in wp_insert_post during import" is enabled - WPML
![wp query - After inserting new post with wp_insert_post() the post is not visble to WP_Query, but the same WP_Query works for post inserted from wp-admin panel - WordPress Development Stack Exchange wp query - After inserting new post with wp_insert_post() the post is not visble to WP_Query, but the same WP_Query works for post inserted from wp-admin panel - WordPress Development Stack Exchange](https://i.stack.imgur.com/Qtjdv.png)
wp query - After inserting new post with wp_insert_post() the post is not visble to WP_Query, but the same WP_Query works for post inserted from wp-admin panel - WordPress Development Stack Exchange
![php - wp_insert_post hook doesn't work when I publish a post from public area. But works fine from admin area. Why? - Stack Overflow php - wp_insert_post hook doesn't work when I publish a post from public area. But works fine from admin area. Why? - Stack Overflow](https://i.stack.imgur.com/Wb9JF.png)
php - wp_insert_post hook doesn't work when I publish a post from public area. But works fine from admin area. Why? - Stack Overflow
![wp query - After inserting new post with wp_insert_post() the post is not visble to WP_Query, but the same WP_Query works for post inserted from wp-admin panel - WordPress Development Stack Exchange wp query - After inserting new post with wp_insert_post() the post is not visble to WP_Query, but the same WP_Query works for post inserted from wp-admin panel - WordPress Development Stack Exchange](https://i.stack.imgur.com/FXdAk.png)