Don't miss out Virtual Happy Hour this Friday (April 26).

Try our conversational search powered by Generative AI!

Use the same index for multiple sites?

Vote:
 

Hi,

I've noticed that siteId is indexed with every document. But does Find allways filter hits on siteId, or is that something we have to do manually?

What I'm really asking is if we can use the same index to multiples sites and version, e.g. staging, dev and so on?

#65115
Jan 21, 2013 14:27
Vote:
 

It doesn't. The SiteId was at least initially indexed to handle multi site/enterprise scenarios rather than different environments. I have heard of some using the same index for dev, staging etc by filtering on SiteId though, but you'd have to do it manually. Personally I'd go for different developer indexes for each non-production environment. Alternatively, if developer indexes causes problems in for instance staging I'd check with EPiServer. Maybe  something can be arranged.

#65131
Jan 21, 2013 20:25
Vote:
 

Is there a way to allways add a filter to the request, just like SearchClient.Instance.Conventions.UnifiedSearchRegistry.ForInstanceOf<PageData>().AlwaysApplyFilter()? And for files too?


In our case there is a multi site scenario. And maybe enable search over multiple websites.

#65146
Jan 22, 2013 13:25
Vote:
 

Is there a way to allways add a filter to the request, just like SearchClient.Instance.Conventions.UnifiedSearchRegistry.ForInstanceOf<PageData>().AlwaysApplyFilter()? And for files too?


In our case there is a multi site scenario. And maybe enable search over multiple websites.

#65147
Jan 22, 2013 13:25
Vote:
 

I take it you mean to add it to non-unified search requests? In that case no, but you could create custom GetResult/GetContentResult/GetPagesResult/GetFilesResult methods that adds such a filter and use those everywhere. There are other options as well, you could plugin various customized classes but custom method(s) is probably the simplest.

#65149
Jan 22, 2013 13:35
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.