Elasticsearch¶
- class wcs.backend.es.es_search.ElasticsearchGet¶
REST API service for Elasticsearch queries with aggregations and suggestions.
- reply()¶
Process the request and return a JSON serializable data structure or the no content marker if the response body should be empty.
- class wcs.backend.es.es_search.ElasticsearchHandler(context, request)¶
Enhanced search handler that includes Elasticsearch aggregations and suggestions.
- search(query=None)¶
Enhanced search method that includes Elasticsearch aggregations and suggestions.
- Args:
query (dict, optional): Search query parameters
- Returns:
dict: Search results with additional elasticsearch.aggregations and elasticsearch.suggest data
- class wcs.backend.es.es_search.RawElasticsearchPost¶
REST API service for raw Elasticsearch queries with security layer.
- reply()¶
Process the request and return a JSON serializable data structure or the no content marker if the response body should be empty.
- class wcs.backend.es.mapping.BackendMappingAdapter(request, manager)¶
Custom Elasticsearch mapping with German text analysis and configurable fields.
Features: - Adds custom German text analyzer with German stopwords - Configurable custom fields via registry setting wcs.backend.search.custom_fields - Applies German analyzer to SearchableText, Title, Description, and content_title fields
- wcs.backend.es.patches.patched__search(self, query, original_query=None, sort=None, **query_params)¶
Enhanced ElasticSearchManager._search with aggregations and suggestions.
- Args:
query: Elasticsearch query dictionary original_query: Original Plone query for suggestion generation sort: Sort parameters query_params: Additional query parameters
- Returns:
dict: Elasticsearch response with aggregations and suggestions
- wcs.backend.es.patches.patched_search(self, query: dict, factory=None, **query_params) LazyMap¶
Enhanced ElasticSearchManager.search with aggregations and titles.
- Args:
query (dict): The Plone catalog query factory: Factory for mapping elasticsearch results (defaults to BrainFactory) **query_params: Additional search parameters including ‘stored_fields’
- Returns:
LazyMap: Search results with aggregations, original_aggregations, and suggest attributes
- class wcs.backend.es.restapi.PopularSearchesGet¶
REST API service that returns popular search terms from registry configuration.
- reply()¶
Process the request and return a JSON serializable data structure or the no content marker if the response body should be empty.
- class wcs.backend.es.result.ElasticResult(manager, query, **query_params)¶
Enhanced Elasticsearch result with aggregations and suggestions.
- class wcs.backend.es.result.ElasticResultFromRawQuery(manager, raw_query, sort, **query_params)¶
Elasticsearch result from raw query with security restrictions applied.
Handles permission checks and inactive content filtering for raw Elasticsearch queries.
- class wcs.backend.es.result.RawElasticResult(manager, raw_query, sort, **query_params)¶
Raw Elasticsearch result for direct query execution with aggregations support.