• Resolved razvanfrandes

    (@razvanfrandes)


    Hello,

    I have a blank theme, only a style and a function.php file.

    I am using only woocommerce plugin.

    Is this normal? To create a product in a empty database via rest-api in 1.5s-2s?

    In the request I send only a title for the product, and a unique sku.

    I dont know what happens with a product that has variations and meta fields… I have added extra indexs in my db, in the wp_wc_product_meta_lookup but still same results. The database is fine, it works fast.

    I know it’s not woocomerces fault, it’s wordpress. But is there a work around? Like adding product via wpdb or just use wpdb for all crud operations. I think this is a question that all devs ask’s maybe for 10 years now, is there such a option?

Viewing 1 replies (of 1 total)
  • Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @razvanfrandes

    It’s not unusual for a product to be created in an empty database via REST API within 1.5 to 2 seconds, even with a minimal setup like yours. The time can vary depending on several factors, including your server’s specifications, network latency, and the complexity of the data being sent.

    As for handling products with variations and meta fields, WooCommerce is designed to handle them efficiently, but depending on the quantity and complexity of the data, it might impact the performance.

    Also, it’s possible to use wpdb for CRUD operations, but it’s not recommended. WooCommerce has its own set of APIs designed specifically for its data structures, which are optimized for performance. Using wpdb directly could bypass these optimizations and potentially cause issues.

    If you’re experiencing slower than expected performance, I’d suggest checking your server’s resources and possibly increasing them, ensuring your WordPress and WooCommerce installations are up-to-date, and checking for any potential network issues.

    I also found some resources online that might be helpful to you:

    I hope this clarifies the matter, and please let us know if you have any other questions.

Viewing 1 replies (of 1 total)
  • The topic ‘Very Slow Rest API’ is closed to new replies.