Modify Sitecore Module Configuration


The Sitecore Module connects your Sitecore CMS to SearchStax SearchStudio for a customized search experience. The Module is helpful and convenient up to the moment when you decide to revise one or more settings. At that point, you’ll need to edit a configuration file.

A typical scenario occurs when you decide to connect your Sitecore instance to a different SearchStudio App. This entails changes to Solr endpoints as well as to the user names and passwords of your Admin and Read-Only Solr users. Spelling correction or auto-suggest endpoints might or might not be included at your preference.

The file to edit is \App_Config\Modules\SearchStax:

<configuration xmlns:patch=http://www.sitecore.net/xmlconfig/>
  <sitecore>
    <searchstax>
      <configs>
        <cloud type="SearchStax.Foundation.Core.Configuration.SearchStaxConfiguration, SearchStax.Foundation.Core" coreIndexName="searchstudio-for-sitecore-test">
          <RootItem>/sitecore/content/tenant/site/home</RootItem>
          <SearchEndpoint>https://ss123456-bhfq2ixl-us-east-1-aws.searchstax.com/solr/searchstudio-for-sitecore-test/emselect</SearchEndpoint>
          <SuggestEndpoint>https://ss123456-bhfq2ixl-us-east-1-aws.searchstax.com/solr/searchstudio-for-sitecore-test/emsuggest</SuggestEndpoint>
          <AuthenticationBasicToken>YXBwNzAtYXBpOkFycmliYSEyMw==</AuthenticationBasicToken>
          <AdminAuthenticationBasicToken>YXBwNzAtYWRtaW46S29uYWJvcyEyMw==</AdminAuthenticationBasicToken>
          <SolrUsername>app70-api</SolrUsername>
          <SolrPassword>Arriba!23</SolrPassword>
          <AdminSolrUsername>app70-admin</AdminSolrUsername>
          <AdminSolrPassword>Arriba!23 </AdminSolrPassword>
          <AnalyticsApiKey>cBVKGLpV3bhcv8vu PBdP0hC5FtxcGnhwOvkK5h6Berw</AnalyticsApiKey>
          <IndexCoreName>searchstudio-for-sitecore-test</IndexCoreName>
        </cloud>
      </configs>
    </searchstax>
  </sitecore>
</configuration>

The meaning of most of these settings should be self-evident from the parameters required by the Sitecore Module. The exceptions would be the AuthenticationBasicToken and the AdminAuthenticationBasicToken.

  • AuthenticationBasicToken: The authentication token for the Read-Only Solr user.
  • AdminAuthenticationBasicToken: The authentication token for the Admin Solr user.

You did not have to provide these values when setting up the Sitecore Module, but any changes to the Read-Only or Admin user credentials will force you to generate new tokens and enter them here along with the new credentials.

Fortunately, there are web sites that generate authentication tokens based on username and password combinations. One of them is the Basic Authentication Header Generator:

Just copy the token from the screen and paste it into the config file.

After editing and saving the config file, you’ll have to restart Sitecore to see the changes take effect.

Questions?

Do not hesitate to contact the SearchStax Support Desk.