Solution to optimize the reindex process?

Created by Jane D, Modified on Mon, 29 Nov, 2021 at 2:01 PM by Jane D

QUESTION:

We bought the extension "Magento Multiple Store View Pricing" for M1 with Order OP10000043977 on Magento 1.9.4


1. Installed it without any issue.

2. Run the Indexation after that and it was running 10-15 minutes, which is very slow.

3. Opened with PHPMyAdmin the SQL table `catalog_product_index_price_store` and I see 3515205 total records.


We have in Store Management 20 websites and 37 store views in total. Some of the websites have only one store view, some have multiple store views.

Also, we have 3900 products in total.


I have mentioned that in that SQL table `catalog_product_index_price_store` too many unnecessary records.

I have a record with website_id with all 37 store_id (all store views), even if the store view is not from this website.


Why do I need a record with store_id that is not belong to that website?

Would you check this issue because if we double our products and store view the SQL table `catalog_product_index_price_store` will grow a lot more? 


This should be optimized somehow. 



ANSWER:


Our team has a solution to optimize the reindex process with the files change attached below: 


+ app/code/local/Bss/MultiStoreViewPricingPriceIndexer/Model/Resource/Product/Indexer/Price.php

+ app/code/local/Bss/MultiStoreViewPricingPriceIndexer/Model/Resource/Product/Indexer/Price/Bundle.php

+ app/code/local/Bss/MultiStoreViewPricingPriceIndexer/Model/Resource/Product/Indexer/Price/Default.php

+ app/code/local/Bss/MultiStoreViewPricingPriceIndexer/Model/Resource/Product/Indexer/Price/Grouped.php



Please download the files attached below to override the current files on your site.

If you need any further assistance, please feel free to contact us. We'd be happy to support!   



Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article