Realtime Indexing instead of periodic reindexing
Posted: Tue Oct 06, 2015 6:02 am
As I understand the way broadleaf indexes products, it periodically reindexes ALL products with a configurable interval. Reindexing is expensive and I want to index a single product or a subset of products only after the following actions:
1. Save a product in Admin
2. Delete a product in Admin
3. Change the list of CategoryProductXref in the Category admin section.
4. Please indicate other cases where a product/products need to be reindexed.
Are SolrIndexService.buildIncrementalSkuIndex() and SolrIndexService.buildIncrementalProductIndex() the places
where I should reindex skus and products?
Should I call theses methods in a JPA event listener after the EntityManager persist/save/delete an Product or Category?
Thank you.
1. Save a product in Admin
2. Delete a product in Admin
3. Change the list of CategoryProductXref in the Category admin section.
4. Please indicate other cases where a product/products need to be reindexed.
Are SolrIndexService.buildIncrementalSkuIndex() and SolrIndexService.buildIncrementalProductIndex() the places
where I should reindex skus and products?
Should I call theses methods in a JPA event listener after the EntityManager persist/save/delete an Product or Category?
Thank you.