woocommerce-blocks
woocommerce-blocks copied to clipboard
AbstractProductGrid huge performance issues
Hello, I am seeing huge performance issues stemming from the AbstractProductGrid implementation. In a page with 3 blocks of 3x7 grid of products we are seeing response times of 4 seconds and upwards.
If I comment this part of the code or cache it super aggressively, the response times immediately jump to sub 500ms,
My initial suspicions are that the products on line 79; in the AbstractProductGrid file are queried inefficiently.
I'm also wary of this part, which might be a source of performance issues.
This issue makes AbstractProductGrid unusable in anything that is more complex. I think we should look to improve the performance here.
To reproduce
Steps to reproduce the behavior: Use n x n product grids where n is >~ 4 in multiple places in one page.
Expected behavior
Response times that are not as slow as 4 seconds and upwards