[buddypress-trac] [BuddyPress] #4060: slow queries in bp-core-classes

buddypress-trac at lists.automattic.com buddypress-trac at lists.automattic.com
Fri Mar 2 23:03:57 UTC 2012


#4060: slow queries in bp-core-classes
--------------------------+-----------------------------
 Reporter:  shanebp       |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Core          |    Version:  1.2.9
 Severity:  normal        |   Keywords:
--------------------------+-----------------------------
 Apologies if this shouldn't be a ticket...

 We have ~25k users.

 We’re still on BP Version 1.2.9 – (working on upgrading to 1.3)

 I’m wondering if the issue below is addressed by 1.3 and/or if there is
 something we can do on 1.2.9

 Here is an example of a slow query:
 SELECT DISTINCT u.ID as id, u.user_registered, u.user_nicename,
 u.user_login, u.display_name, u.user_email , um.meta_value as
 last_activity FROM wp_users u LEFT JOIN wp_usermeta um ON um.user_id =
 u.ID WHERE u.user_status = 0 AND um.meta_key = 'last_activity' ORDER BY
 um.meta_value

 I think this is coming from bp-core-classes -> function get_users

 We’ve increased :
 query_cache_size to 128M
 query_cache_limit: to 2M
 join_buffer_size to 2M

 But we still have problems during high traffic.

 Any suggestions on optimizing that query or some other approach ?

-- 
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/4060>
BuddyPress <http://buddypress.org/>
BuddyPress


More information about the buddypress-trac mailing list