Search in Kentico SaaS

2025/01/25 9:28 PM

We're in the process of migrating a client site from another CMS to Kentico's SaaS offering. Is there any guidance on how to implement something akin to the K13 Smart Search in this environment? We could go the route of something like Lucene, but I'm not sure how we'd store the index files. We could map them to blob storage, but how would that affect performance?


Environment

  • Xperience by Kentico version: 29.7.0
  • .NET version: 8
  • Execution environment: Saas

Answers

2025/01/25 10:22 PM

The website you are using to ask your question is running on Xperience by Kentico, v30.1.0 (at the time of this answer), and hosted in Kentico's SaaS environment.

It also uses Lucene.NET for Q&A and blog search experiences.

We don't map the index files to blob storage for the Community Portal, but if you did it would give you the benefit of having the files immediately available on scale-out, which the SaaS environment handles for you.

We also have integrations for Algolia and Azure AI Search if you are concerned about Lucene.NET's capabilities/scalability.

2025/01/27 2:28 PM

How do you handle scale-out with these indexes? I recall on a past K13 project running into the issue that a newly scaled server didn't have the Lucene indexes and wouldn't return search results. It think my solution was to listen for the global event that was fired when a new server was added to the web farm and kick off an index rebuild on that server.

My only other experience with using Lucene in a cloud environment was limited to the K13 media file usage index. That particular site was running in an Azure App Service, and there were specific instructions in the documentation to store those indexes in blob storage. It seemed to work fine, although the local Azure quickly filled with Lucene's temporary files. Would we need to make any sort of setting changes like that for Kentico's Saas?

2025/02/07 4:59 PM
Answer

Sorry for the delayed response.

I don't know if those web farm events are available in Xperience by Kentico, but you could respond to the ApplicationEvents.PostStart event and trigger a rebuild. Each time the web farm scaled out the new application would have an up-to-date local index. This would also trigger on application restarts, so you'd need to consider this if your index creation was resource intensive.

Xperience's Lucene integration rotates through a limited number of indexes, so you shouldn't need to worry about filling up your storage in SaaS or private cloud hosting.

To answer this question, you have to login first.