Download the PHP package somardesignstudios/silverstripe-elastic-search without Composer
On this page you can find all versions of the php package somardesignstudios/silverstripe-elastic-search. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download somardesignstudios/silverstripe-elastic-search
More information about somardesignstudios/silverstripe-elastic-search
Files in somardesignstudios/silverstripe-elastic-search
Package silverstripe-elastic-search
Short Description A silverstripe module providing search with elasticsearch
License BSD-3-Clause
Informations about the package silverstripe-elastic-search
SilverStripe elastic search
Silverstripe module to provide site-wide content search with elasticsearch
Requirements
- SilverStripe ^4.0
- elasticsearch-php
- ramsey/uuid
- SilverStripe Queued Jobs Module
Installation
-
Install the module
- Create
log
folder in the root of the project with permissions allowing write to the user running the site
Elastic connection configuration
Add your elasticsearch API keys to the .env file
Search configuration
Field mappings configuration
Page content will be flattened and stored in a standard set of fields defined in this module's search.yml
You can add additional fields by adding a search.yml
config to your own project. e.g.
Search fields
You can change the default search fields and its weightings in config file, optionally you can define highlighting matches in matched fields:
Search page
On the Search page you will find a Vue component that is configurable via .yml files:
Search type
You can add additional configurations sets when multiple search pages with different configurations are needed. When an additional search type is defined, a dropdown will appear on the Search page. Configuration of additional search type is then merged with the default one.
Index creation
To create the index run /dev/tasks/Somar-Search-Task-CreateIndexTask
. This task will create the index, set the mapping and create a pipeline for processing attachments.
When the index is created, use SearchIndexJob
to index the site content (objects of class Page). You can add additional classes to index via .yml config:
All versions of silverstripe-elastic-search with dependencies
elasticsearch/elasticsearch Version ^7.6
ramsey/uuid Version ^4.7
symbiote/silverstripe-queuedjobs Version ^4.0 || ^5.0
silverstripe/segment-field Version ^2.0 || ^3.0