Banner Logo

Be a part of the family: Connect, Receive Support,
Contribute, and Reap Abundant Rewards!

Slowness in WP-Admin

Theme and Plugin Support

Tagged: 

Resolved
Viewing 9 reply threads
  • Author
    Posts
    • #124820
      odedtalmon
      Participant

      Hello,
      The WP admin is very slow, takes 5s on average to load any page, so I installed Query Monitor and it shows a slow query, view attached image for inspection.

      Why is

      wcmp_get_orders()
      Copy

      even running on the backend on LiteSpeed Cache plugin’s pages?

    • #124856

      Hi,
      wcmp_get_orders function just return wcmp suborders. This comes from WP_Query ( like default wordpress query funtion ). You might have huge data in your one page.
      Thanks

    • #124858
      odedtalmon
      Participant

      Hey Raju!
      The thing is that this query runs on all pages on the WP-Admin

    • #124936

      Hi,
      As per our default code, we don’t call these functions to all the pages. So “The thing is that this query runs on all pages….” this is not possible. We have checked the code again. In the admin section, we have called this function in the time to order menu count. We have also checked the query plugin. But don’t find any such issue. This might be due to huge order data.

    • #124977
      odedtalmon
      Participant

      16,500 orders is considered huge?
      If it is what do you recommend I do in order to help with the slowness?
      Thanks Raju!

    • #124998

      Hi,
      This is completely site-specific ( may occur due to database data ). Or you need to check each and every line code to find the issue. Which is time-consuming and difficult. As per your query monitor debug result, we have used wcmp_get_orders() this function for counting post. You can do one thing — remove this section — Please check by using this code. It may help. But not sure.

      add_action('init', function() {
          global $WCMp;
          remove_filter('woocommerce_menu_order_count', array($WCMp->admin, 'woocommerce_admin_end_order_menu_count'));
      });
      Copy

      Thanks

    • #125016
      odedtalmon
      Participant

      Hello Raju,
      The code your provided makes a significant difference in WP-Admin pages loading times.
      Could you say if there are any implications to this?
      Thank you!

    • #125101

      @odedtalmon, the above code, should not cause any other issue.

    • #125102
      odedtalmon
      Participant

      Thank you Raju!

    • #125104

      You are welcome 🙂

Viewing 9 reply threads

The topic ‘Slowness in WP-Admin’ is closed to new replies.