0

Do we have any general instructions to follow to implement any custom search provider in Sitecore other than officially supported Solr and Azure Search?

We need to implement for Algolia search provider.

Already looked at two repositories out there:

https://github.com/dharnitski/Sitecore.Algolia

https://github.com/chorpo/Sitecore.Algolia/tree/sitecore91

Upgraded code and configurations to support Sitecore latest version (10.1), but Custom Index doesn't show on the Indexing Manager. No error in logs. Any help would be highly appreciated.

What mainly drives a particular index to show on the Indexing Manager? We are using Solr for all the Sitecore default Indexes (they are showing up) and using Algolia for Custom Indexes.

0

It is a difficult one to answer completely. Putting in answer instead of comment because of the length.

Based on this link https://doc.sitecore.com/en/developers/91/platform-administration-and-architecture/configure-a-search-and-indexing-provider.html

Sitecore supports 3 search providers at the moment. Good to first quick check with Sitecore support if Custom Search provider is possible or not. Means are there any hard coded references of these 3 options in core Sitecore dlls.

We have below,

For Solr = webroot\App_Config\Sitecore\ContentSearch

For Azure = webroot\App_Config\Sitecore\ContentSearch.Azure

May be for custom search provider we may duplicate one of this folder and explore the configuration and provide custom classes wherever necessary.

>>What mainly drives a particular index to show on the Indexing Manager?

Upon checking backend of indexing manager dialog i.e. Sitecore.ContentSearch.Client.Forms.IndexingManagerWizard

webroot\sitecore\shell\Applications\ContentSearch\IndexingManager.xml

Indexes information are fetched from ContentSearchManager.Indexes

This leads to..

public static IEnumerable Indexes => (IEnumerable) ContentSearchManager.SearchConfiguration.Indexes.Values;

=>

Checked AddIndex method in Sitecore.ContentSearch.ContentSearchConfiguration which actually adds the indexes information based on Sitecore.ContentSearch.{SearchProvider}.Index.{Database}.config (e.g Sitecore.ContentSearch.Azure.Index.Master.config) or your copy of this file to implement the custom indexing used by your provider.

Basically we need to satisfy the required custom types used in above config specific to search provider needs. Like we need to have custom CloudSearchProviderIndex (implementing ISearchService) and CompositeSearchService (implementing ISearchIndex)

These interfaces are used in ContentSearchConfiguration. Good to explore Sitecore.ContentSearch.Azure.dll in dotpeek for all these existing types and have our custom types for custom search provider accordinlgy.

enter image description here

1
  • Note that all references to Azure Cognitive Search now include the following warning: "Azure Search will be discontinued in the future and Sitecore will no longer provide support for this service in future releases." Nov 2 '21 at 18:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.