Tuesday, November 29, 2011

Solr Re-indexing steps WCS 7

Pre-requests: you need to have V7 FEP2+.

IBM WCS is now a fully operational search engine. the product now includes Lucene Solr as the interal search engine, also incorporates industry best practices.


Once you get the latest database, follow these steps to re-index the products.

  1. Install "WebSphere Commerce Developer Enterprise" version 7
  2. Update "WebSphere Commerce Developer Enterprise" to version 7.0.0.5
  3. Stop Server
  4. Enable the Store Enhancement Features
    1. cd WCDE_installdir\bin
    2. enableFeature.bat -DfeatureName=store-enhancements
  5. Publish the Madisons Feature Pack Store Archive:
    1. Publish Madisons-FEP.sar
  6. Enable the Solr foundation
    1. cd WCDE_installdir\bin
    2. enableFeature.bat -DfeatureName=foundation [DsolrHome=C:\IBM\WCDE_ENT70\search\solr\home]
  7. Setup the Search Index: (WC Server must be Stoped)
    1. cd 'WCDE_installdir'\components\foundation\subcomponents\search\bin
    2. setupSearchIndex.bat -masterCatalogId 10001 -instance WCDE_ENT70 -dbuser db2admin -dbuserpwd db2admin [-solrhome C:\IBM\WCDE_ENT70\search\solr\home]
    3. To see log file : \WCDE_ENT70\components\foundation\subcomponents\search\log\wc-search-index-setup.log
    4. Once successfully completed the status code could be : Program exiting with exit code: 0
  8. Preprocess the Search index: (Run the di-preprocess.bat file against the search index, again server stopped at this point)
    1. cd WCDE_installdir\bin
    2. di-preprocess.bat C:\IBM\WCDE_ENT70\search\pre-processConfig\MC_10001\DB2\ [-fullbuild true] [-localename en_US]
  9. Test the current Solr index to ensure that a request can be recognized: (Server should be started)
    1. http://host_name/solr/Default/select?q=*%3A*
  10. Build out the index (first make sure to start the WC server):
    1. cd WCDE_installdir\bin
    2. di-buildindex.bat -masterCatalogId 10001 
  11. Test the indexed Solr index to ensure results are returning:
    1. http://localhost/solr/MC_10001_CatalogEntry_en_US/select?q=catentry_id:10251
  12. Enable the store to display the search breadcrumb and faceting filters:
    1. Open Management Center
    2. Click "Management Center Tools" menu and select "Store Management"
    3. Select the "Madisons" store and click the "Catalog" tab
    4. check "Search-based navigation"
    5. click Save
  13. Test live on the starter store:
    1. http://localhost/webapp/wcs/stores/servlet/Madisons/index.jsp
    2. http://localhost/webapp/wcs/stores/servlet/en/eliteesite/home

No comments:

Post a Comment