Enable SOLR for Commerce Connect

Enable SOLR for your Sitecore Commerce 7.5, powered by Commerce Server and Commerce Server 11.1 solution if you are using Commerce Connect.

Note: SOLR is not required to use Commerce Connect.

At the desktop of your Sitecore Commerce 7.5, powered by Commerce Server and Commerce Server 11.1 machine:

  1. Set the address to the SOLR instance in App_Config\Include\MVCSite\MVCSite.config.
  2. Copy the default Schema.xml from the deployed SOLR server.
  3. Generate the SOLR Schema.xml file.
    At your Sitecore desktop, click Sitecore > Control Panel > Indexing > Generate the Solr Schema.xml file and follow the instructions in the Build Solr Schema Wizard.
  4. Add the following dynamic fields and field type to the generated schema.xml file.
    Add the following to schema.xml
    <dynamicField
            name="*_tm" type="text_general" indexed="true" stored="true"
            multiValued="true"/>            <dynamicField name="*_sci" type="string_ci" indexed="true"
            stored="true" />             <fieldType name="string_ci" class="solr.TextField"
            sortMissingLast="true" omitNorms="true">       
            <analyzer>           
            <tokenizer class="solr.KeywordTokenizerFactory"/>          
                      <filter class="solr.LowerCaseFilterFactory"
          />       
            </analyzer>            </fieldType>
  5. Copy the updated schema file to SOLR server.
  6. Add additional itembuckets to the SOLR config to support indexes.
    1. Ensure SOLR is not running.
    2. Navigate to the SOLR installation directory to \example\solr
    3. Copy the itembuckets folder.
    4. Rename the copy itembuckets_commerce_products_master_index.
    5. Open the folder itembuckets_commerce_products_master_index.
    6. Delete the data folder.
    7. Open the core.properties file.
    8. Update the name property to itembuckets_commerce_products_master_index
    9. Copy the itembuckets folder.
    10. Rename the copy itembuckets_commerce_products_web_index.
    11. Open the folder itembuckets_commerce_products_web_index.
    12. Delete the data folder.
    13. Open the core.properties file.
    14. Update the name property to itembuckets_commerce_products_web_index
  7. Restart the SOLR service.
  8. Enable SOLR .
    Run ToggleSearchProvider.ps1 from the integration packages to switch from lucene to SOLR.
    Update the $instanceName to the Sitecore instance
    Change the $installDir path, if required..
  9. Index the site .
    Click Sitecore > Control Panel > Indexing > Indexing Manager and follow the instructions in the wizard.