• Resolved Marco

    (@mcbus94)


    Hi guys

    I use Google Site Plugin and I have identify this slow query that could be improved:

    SELECT SQL_CALC_FOUND_ROWS wp5x_users.ID
    FROM wp5x_users
    INNER JOIN wp5x_usermeta
    ON ( wp5x_users.ID = wp5x_usermeta.user_id )
    WHERE 1=1
    AND ( ( ( wp5x_usermeta.meta_key = 'wp5x_capabilities'
    AND wp5x_usermeta.meta_value LIKE '%\"Administrator\"%' ) ) )
    ORDER BY user_login ASC
    LIMIT 0, 1
Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Evan Mattson

    (@aaemnnosttv)

    Hi Marco, thanks for bringing this to our attention. Can you share any more detail about how long this query is taking for you? It would also be useful if you could share your Site Health information with us via this private form.

    Thread Starter Marco

    (@mcbus94)

    I have just shared the site health.

    It’s the slowest query in my site. Here following query monitor report:

    with google site kit plugin: 2.54s, 102MB, 0,26s, 803queries

    without google site kit plugin: 1.82s, 72MB, 0.17s, 711queries

    please note I performed the test on a page that is not cached

    Thank you

    Plugin Author Evan Mattson

    (@aaemnnosttv)

    Thanks for sharing that. It looks like there is a bug which causes this query to happen more than it should, so I’ll open an issue to get this fixed, otherwise it should have a negligible impact on your site’s loading time. Note that this query only happens when you (as a user who can use Site Kit) is logged in and on a page where Site Kit is loaded, so it shouldn’t be affecting other users on the site.

    Also, it’s unlikely that this one query is accounting for the entire difference in timing that you’re seeing with and without Site Kit. Site Kit does add some queries when enabled but again, this should only affect users that are logged in and on pages where Site Kit has a presence in wp-admin.

    Plugin Support James Osborne

    (@jamesosborne)

    Just as an update on this @mcbus94, we’re working on a fix for this, with details below:
    https://github.com/google/site-kit-wp/issues/11717

    We expect this fix to be part of the next release, set for next week. We’ll let you know once it’s out. Thanks for the input!

    Plugin Support James Osborne

    (@jamesosborne)

    Just to let you know that the latest version of Site Kit has been released, and this contains a fix for this issue that you raised. Many thanks for bringing this to our attention! Please update to this latest version, and ask if you have any further questions on this.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Slow query’ is closed to new replies.