Interface ElasticsearchSearchStrategy

All Superinterfaces:
SearchStrategy
All Known Implementing Classes:
AnyTermAnyFieldElasticsearchSearchStrategy, PhraseElasticsearchSearchStrategy, StartsWithElasticsearchSearchStrategy

public interface ElasticsearchSearchStrategy extends SearchStrategy
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    configureRequest(co.elastic.clients.elasticsearch.core.SearchRequest.Builder requestBuilder, SearchContext searchContext)
    Configures Elasticsearch SearchRequest.

    Methods inherited from interface io.jmix.search.searching.SearchStrategy

    getName
  • Method Details

    • configureRequest

      void configureRequest(co.elastic.clients.elasticsearch.core.SearchRequest.Builder requestBuilder, SearchContext searchContext)
      Configures Elasticsearch SearchRequest.

      The main step - create appropriate query based on provided SearchContext and set it to request.

      Configuration of another request parameters is optional.

      Highlighting, size and offset shouldn't be configured here - these parameters will be overwritten.

      Parameters:
      requestBuilder - allows to configure search request
      searchContext - contains details about search being performed