Log in
Model

EngineResolver

Magento\Search\Model\EngineResolver

What it does

This class determines which search engine (MySQL, Elasticsearch, OpenSearch, etc.) is currently configured and active in Magento 2.

Developers use it to retrieve the current search engine identifier when implementing search functionality or integrating third-party search solutions.

It validates the configured engine against available options and falls back to a default if the configuration is invalid.

Public Methods

  • getCurrentSearchEngine()