"CloudSearchResults constructor not found" error in Azure Search


Description

Search queries against Azure Search might fail with an error similar to the following:

Exception System.MissingMethodException: Constructor on type 'Sitecore.ContentSearch.Azure.Query.CloudSearchResults`1[[Sitecore.ContentSearch.SearchTypes.SearchResultItem, Sitecore.ContentSearch, Version=4.0.0.0, Culture=neutral, PublicKeyToken=null]]' not found.

For SXA sites, refer to the CloudSearchResults constructor not found error when using Azure Search provider with SXA.

Solution

To resolve the issue, consider one of the following options: