This project is not covered by Drupal’s security advisory policy.
INTRODUCTION
This module is a extended version of Search API Synonym(search_api_synonym) module. It provides integration with Apache Solr and export synonyms directly in solr configuration (no need to update synonyms_und.txt file).
REQUIREMENTS
NEW FEATURES AND CHANGES
Apache SOLR integration and export synonyms directly in solr was missing in Search API Synonym module so we have implemented this feature and provided compatibility for drupal 9 version and some minor updates.
INSTALLATION
Install as you would normally install a contributed drupal module. See: https://www.drupal.org/documentation/install/modules-themes/modules-8 for further information.
MANAGE SYNONYMS
After installation can you start managing your synonyms and spelling errors
at admin/config/search/solr-search-synonyms.
INSTRUCTIONS
Please view the project's README for detailed installation and working instructions.
EXPORT SYNONYMS
Export synonyms using the Drush command:
drush solr-search-synonym:export
drush ssolr-syn:export
drush ssolr-syn-ex
Examples
Export all english synonyms and spelling errors in the Solr format.
[COMMAND] --plugin=solr --langcode=en
For exporting synonyms directly into the solr -
Update SynonymGraphFilterFactory class setting with ManagedSynonymGraphFilterFactory with managed attribute in /solr/data/{index_name}/conf/schema_extra_types.xml file OR just use the POST Method, Screenshot attached for reference.
For Example -
- Configure the SOLR backend server and index on admin/config/search/solr-search-api.
- Update SynonymGraphFilterFactory with ManagedSynonymGraphFilterFactory for fieldType name="text_und" in /solr/data/{index_name}/conf/schema_extra_types.xml file OR just use the POST Method, Screenshot attached for reference. This configuration worked with 8.9.0 solr version. For other versions and field types, configuration may be differ.
- Restart SOLR.
- Execute below command - [COMMAND] --plugin=solr_uploader --langcode=en
- Verify Synonyms with current site search.
For more details, please review README.txt file.
Cron
Export using Drupal cron is supported. See the settings in /admin/config/search/solr-search-synonyms/settings.
For exporting synonyms directly into the solr make sure to update schema_extra_types.xml file first and restart solr. then while cron executed, the synonyms will be exported succussfully in solr.
DEVELOPERS
The Solr Search Synonym module provides the following ways for developers to extend the functionality:
Plugins
Export plugin - see the annotation and the Solr plugin:
- Drupal\solr_search_synonym\Annotation\SearchSearchSynonymExport
- Drupal\solr_search_synonym\Plugin\solr_search_synonym\export\Solr
- Drupal\solr_search_synonym\Plugin\solr_search_synonym\export\SolrUploader
MAINTAINERS
Current maintainers:
Attachment | Size |
---|---|
POST Method | 80.65 KB |
GET Method | 108.51 KB |
Project information
- Module categories: Site Search, Integrations
- Ecosystem: Search API Synonym
- 58 sites report using this module
- Created by bhojwanipankaj05 on , updated
- This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.