NuGet ยท nuget

Redeon.SuperSiteEngineCore.Web.Eltheon.Core.Features.SimpleSearch

Core Feature for Simple Search indexing within the Eltheon framework

Install

Install-Kommandos

dotnet add package Redeon.SuperSiteEngineCore.Web.Eltheon.Core.Features.SimpleSearch --version 2.9.1
<PackageReference Include="Redeon.SuperSiteEngineCore.Web.Eltheon.Core.Features.SimpleSearch" Version="2.9.1" />
paket add Redeon.SuperSiteEngineCore.Web.Eltheon.Core.Features.SimpleSearch --version 2.9.1
Install-Package Redeon.SuperSiteEngineCore.Web.Eltheon.Core.Features.SimpleSearch -Version 2.9.1

README

Vorschau

Redeon.SuperSiteEngineCore.Web.Eltheon.Core.Features.SimpleSearch

Purpose

SimpleSearch indexes localized Admin/User page metadata into the Eltheon in-memory store and exposes a lightweight query surface for the global shell search.

The feature owns:

  • indexing services and in-memory index access,
  • ISimpleSearchQuery,
  • GET /api/v1/SimpleSearch,
  • metric definitions for index rebuild and query activity.

The template owns the global header modal that calls the API.

Registration

Register SimpleSearch services in the host/template:

builder.Services.AddEltheonSimpleSearch();

Register the API application part on the MVC/Razor builder that should discover feature-owned controllers:

builder.Services.AddMvc()
    .AddEltheonSimpleSearchApplicationPart();

Query Behavior

ISimpleSearchQuery.Search(query, areaFilter, CultureInfo.CurrentUICulture) normalizes the query and area filter before searching.

  • Empty, whitespace, or one-character queries return an empty result set.
  • Missing culture indexes return an empty result set instead of null.
  • Title, description, and keywords are searched.
  • Area filtering matches both /Admin and /Admin/... style URLs.
  • Results are limited for shell search usage.

The API response includes results, culture, normalized query, normalized area, and indexAvailable.

Metadata Convention

Searchable Admin/User pages should expose these page resource keys:

  • Meta_SimpleSearch_Title
  • Meta_SimpleSearch_Keywords
  • Meta_SimpleSearch_Description

Search metadata belongs to the owning feature package together with the page resources. Do not maintain a separate hardcoded global search list for feature pages.

Missing Index Behavior

If no compatible metadata localizer is available, indexing is skipped and logged instead of failing application startup. Query callers still receive an empty result set.

Header Integration

The template Admin header uses /api/v1/SimpleSearch with URLSearchParams, debounce, empty/error/loading states, and the existing AdminTheme tokens in admin.css.