Live Search is installed as an extension from Adobe Marketplace. After the Live Search module (with catalog modules as dependencies) is installed and configured, Commerce begins sharing search and catalog data with SaaS services. At this point, Admin users can set up, customize, and manage search facets, synonyms, and merchandising rules.
This topic provides instructions to do the following:
Do the following:
Choose the onboarding method that meets your requirements and follow the instructions.
Due to the Elasticsearch 7 end-of-support announcement for August 2023, it is recommended that all Adobe Commerce customers migrate to the OpenSearch 2.x search engine. For information about migrating your search engine during product upgrade, see Migrating to OpenSearch in the Upgrade Guide.
This onboarding method is recommended when installing Live Search to a:
In this scenario, storefront operations are interrupted while the Live Search service indexes all products in the catalog. During the installation, Live Search modules are enabled and OpenSearch modules are disabled.
Install Adobe Commerce 2.4.4+ without Live Search.
To download the live-search
package, run the following from the command line:
composer require magento/live-search
Run the following commands to disable OpenSearch and related modules, and install Live Search:
bin/magento module:disable Magento_Elasticsearch Magento_Elasticsearch7 Magento_OpenSearch Magento_ElasticsearchCatalogPermissions Magento_InventoryElasticsearch Magento_ElasticsearchCatalogPermissionsGraphQl
bin/magento setup:upgrade
While the data is indexed and synchronized, the search and category browse operations are not available in the storefront. Depending on the size of your catalog, the process can take at least an hour from the time cron
runs to synchronize your data to Live Search services.
Verify that the following indexers are set to “Update by Schedule”:
Configure your API keys and verify that your catalog data is synchronized with Live Search services.
To make facets available as filters in the storefront, add the facets you need, according to the faceting requirements.
You should be able to add facets after cron
runs the attribute feeds and exports attribute metadata.
Wait at least an hour after cron
runs to synchronize data. Then, verify that the data was exported.
Test the connection from the storefront.
This onboarding method is recommended when installing Live Search to:
In this scenario, OpenSearch temporarily manages search requests from the storefront while the Live Search service indexes all products in the background, without any interruption to normal storefront operations. OpenSearch is disabled and Live Search enabled after all catalog data is indexed and synchronized.
To download the live-search
package, run the following from the command line:
composer require magento/live-search
Run the following command to temporarily disable the Live Search modules that serve storefront search results.
bin/magento module:disable Magento_LiveSearchAdapter Magento_LiveSearchStorefrontPopover
bin/magento setup:upgrade
Elasticsearch continues to manage search requests from the storefront while the Live Search service synchronizes catalog data and indexes products in the background.
Verify that the following indexers are set to “Update by Schedule”:
Configure your API keys and verify that your catalog data is synchronized with Live Search services.
To make facets available as filters in the storefront, add the facets you need, according to the faceting requirements.
You should be able to add facets after cron
runs the product and attribute feeds and exports attribute metadata to Live Search services.
Wait at least an hour for the data to be indexed and synchronized. Then, use the GraphQL playground with the default query to verify the following:
Run the following commands to enable Live Search modules, disable OpenSearch, and run setup
.
bin/magento module:enable Magento_LiveSearchAdapter Magento_LiveSearchStorefrontPopover
bin/magento module:disable Magento_Elasticsearch Magento_Elasticsearch6 Magento_Elasticsearch7 Magento_ElasticsearchCatalogPermissions Magento_InventoryElasticsearch
Magento_ElasticsearchCatalogPermissionsGraphQl
bin/magento setup:upgrade
Test the connection from the storefront.
The Adobe Commerce API key and its associated private key are required to connect Live Search to an installation of Adobe Commerce. The API key is generated and maintained in the account of the Commerce license holder, who can share it with the developer or SI. The developer can then create and manage the SaaS Data Spaces on behalf of the license holder. If you already have a set of API keys, you do not need to regenerate them.
To generate an API key and private key, refer to Commerce Services Connector.
The developer or SI configures the SaaS data space as described in the Commerce Services section of the configuration. In the Admin, Commerce Services becomes available in the Configuration sidebar when a SaaS module is installed.
Live Search requires synchronized product data for search operations, and synchronized attribute data to configure facets. The initial synchronization between the product catalog and the catalog service begins when Live Search is first connected. Depending on the installation method and size of the catalog, it can take up to 30 minutes for the data to be exported and indexed by Live Search. The list of data that is synchronized and shared with the catalog service can be found in the schema, which is defined in:
vendor/magento/module-catalog-data-exporter/etc/et_schema.xml
To verify that the catalog data has been exported from your Adobe Commerce instance and is synchronized for Live Search, look for entries in the following tables:
catalog_data_exporter_products
catalog_data_exporter_product_attributes
For additional help, refer to Live Search catalog not synchronized in the Support Knowledge Base.
After the initial synchronization, it can take up to 15 minutes for incremental product updates to become available to storefront search. To learn more, go to Indexing - Streaming Product Updates.
In the storefront, verify the following:
If everything works correctly, congratulations! Live Search is installed, connected, and ready to use.
If you encounter problems in the storefront, check the var/log/system.log
file for API communication failures or errors on the services side.
To allow Live Search through a firewall, add commerce.adobe.io
to the allow list.
Before updating Live Search, run the following from the command line to check the version of Live Search that is currently installed:
composer show magento/module-live-search | grep version
To update Live Search, run the following from the command line:
composer update magento/live-search --with-dependencies
To update to a major version such as from 3.1.1 to 4.0.0, edit the project’s root Composer .json
file as follows:
If your currently installed magento/live-search
version is 3.1.1
or below, and you are upgrading to version 4.0.0
or higher, run the following command before the upgrade:
bin/magento module:enable Magento_AdvancedSearch
For information about the currently installed magento/live-search
version, run the following command:
composer show magento/live-search
Open the root composer.json
file and search for magento/live-search
.
In the require
section, update the version number as follows:
"require": {
...
"magento/live-search": "^4.0",
...
}
Save composer.json
. Then, run the following from the command line:
composer update magento/live-search --with-dependencies
To uninstall Live Search, refer to Uninstall modules.
Package | Description |
---|---|
module-live-search |
Allows merchants to configure their search settings for faceting, synonyms, query rules, etc., and provides access to a read-only GraphQL playground to test queries from the Admin. |
module-live-search-adapter |
Routes search requests from the storefront to the Live Search service and renders the results in the storefront. - Category browse - Routes requests from the storefront top navigation to the search service. - Global search - Routes requests from the quick search box in the upper-right of the storefront to the Live Search service. |
module-live-search-storefront-popover |
A “search as you type” popover replaces the standard quick search and returns data and thumbnails of top search results. |
The following Live Search dependencies are captured by Composer.
magento/module-saas-catalog
magento/module-saas-category
magento/module-saas-category-permissions
magento/module-saas-product-override
magento/module-saas-product-variant
magento/module-saas-price
magento/module-saas-scopes
magento/module-bundle-product-data-exporter
magento/module-catalog-inventory-data-exporter
magento/module-catalog-url-rewrite-data-exporter
magento/module-configurable-product-data-exporter
magento/module-parent-product-data-exporter
magento/module-gift-card-product-data-exporter
magento/module-bundle-product-override-data-exporter
data-services
services-id