[wp-hackers] 2.0.4 Performance Issues

Paul Mitchell wp-hackers at paul-mitchell.me.uk
Sun Aug 6 12:33:30 GMT 2006


Robert Deaton wrote:
> I believe I have found part of the cause of the 2.0.4 performance
> issues complaints. Somewhere between 2.0.3 and 2.0.4, we did something
> that calls get_post tens to hundreds of times depending on the number
> of pages when viewing a page with a permalink. This is now completely
> reproducable, and is a serious concern as I have one client who is
> getting in excess of 300 database queries per page view.

Give that man a cigar! Thanks to your use case, I've exposed what must
be considered a performance issue in WP_Query::get_posts() - the search
for a single page id by name is linear, calling get_page() each
iteration until the desired page is found. On a shared site with a
significant number of pages, that could grind.

http://trac.wordpress.org/browser/tags/2.0.4/wp-includes/classes.php#L379

My working is here:
http://libertini.net/libertus/2006/08/06/wordpress-204-performance/

I'm not fixing it! :)

-- 
Paul Mitchell, Coding and Crafting Quality Software
http://www.libertini.net/libertus/category/software/




More information about the wp-hackers mailing list