• Hi,
    When running the plugin on my site, I saw that my server gets a very high CPU.
    When analyzing the logs, I realized a few things:
    * admin-ajax.php was called very frequently (less than one second apart) for the entire duration of the checks
    * The calls to admin-ajax came from the plugin’s backend page.
    * each call to admin-ajax takes around 1-2 seconds at my site (remember that there’s a new call to admin-ajax every less than a second)

    the result is that if I keep the plugin’s backend page open while it’s running, before too long, my server can’t handle the pace and CPU reaches near 100%.

    Note: throttling delay time, maximum execution time and scan technique seemed to have no effect.

    Thanks

    https://www.ads-software.com/plugins/google-pagespeed-insights/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Matt Keys

    (@mattkeys)

    Really interesting. I am out of town right now but I’d like to look into this when I get back.

    In the meantime can you share information about your hosting provider and plan?

    Thanks!

    Thread Starter noamklier

    (@noamklier)

    Thanks for the prompt reply.
    We have a VPS with 8GB and 6 cores at Glesys.

    But I doubt if that’s the server. The fact is that admin-ajax.php is a heavy process on this site. It’s not a simple WP site – we has many custom and third party plugins installed that are necessary for our daily operations. The more plugins we have (and the more complex they are), the slower admin-ajax becomes.
    Now, we usually don’t encounter this kind of problem with other plugins that use admin-ajax since most plugins call it at-most once per load. But if calling it every second for the entire run, then it starts to create problems.

    Plugin Author Matt Keys

    (@mattkeys)

    Hi Noamklier,

    I am currently testing a beta of v2.0 of my plugin which I believe will resolve the issues that you are seeing. Would you be willing to help beta test?

    Thread Starter noamklier

    (@noamklier)

    Thanks for your reply.
    Yes, I will be willing to beta-test.

    Plugin Author Matt Keys

    (@mattkeys)

    Wonderful, thank you!

    Can you contact me through my sites contact form so that I have your email address for sending you the beta?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘High CPU when running plugin’ is closed to new replies.