plugin:elasticsearch
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
plugin:elasticsearch [2019-10-12 03:42] – [Configuration and Settings] StarArmy | plugin:elasticsearch [2024-02-15 12:01] (current) – Aleksandr | ||
---|---|---|---|
Line 2: | Line 2: | ||
---- plugin ---- | ---- plugin ---- | ||
- | description: | + | description: |
author | author | ||
email : dokuwiki@cosmocode.de | email : dokuwiki@cosmocode.de | ||
- | type : action | + | type : action, cli |
- | lastupdate : 2019-07-31 | + | lastupdate : 2023-12-20 |
- | compatible : Greebo | + | compatible : Greebo, Hogfather, Igor, Jack Jackrum, Kaos |
depends | depends | ||
conflicts | conflicts | ||
- | similar | + | similar |
tags : search | tags : search | ||
Line 23: | Line 23: | ||
===== Installation ===== | ===== Installation ===== | ||
- | [[https:// | + | [[https:// |
:!: **External requirements: | :!: **External requirements: | ||
- | * [[https:// | + | * [[https:// |
- | Install | + | Download and install |
Configure and setup the plugin as outlined under [[# | Configure and setup the plugin as outlined under [[# | ||
Line 34: | Line 34: | ||
===== Examples/ | ===== Examples/ | ||
- | Once installed, the plugin will automatically react on the ?do=search action, replacing DokuWiki' | + | Once installed, the plugin will automatically react on the ?do=search action, replacing DokuWiki' |
All [[acl|access rights]] are respected, so users will only find pages for which they have at least read privileges. | All [[acl|access rights]] are respected, so users will only find pages for which they have at least read privileges. | ||
- | You can use the Advanced Search Tools to filter the results by namespace and date of the last modification. | + | You can use the Advanced Search Tools to filter the results by namespace and date of the last modification. With [[plugin: |
+ | |||
+ | If the [[plugin: | ||
===== Configuration and Settings ===== | ===== Configuration and Settings ===== | ||
Line 45: | Line 47: | ||
- enter the configuration of your Elasticsearch server in the [[plugin: | - enter the configuration of your Elasticsearch server in the [[plugin: | ||
+ | - optional: if your ES instance has security enabled (default setting since 8.0), enter the authentication username and password in [[plugin: | ||
+ | - copy and adjust a sample configuration for media indexing | ||
- create the Index | - create the Index | ||
- | - create the Language Mappings | ||
- index your pages | - index your pages | ||
==== Creating the Index ==== | ==== Creating the Index ==== | ||
+ | |||
+ | ==== Indexing media ==== | ||
+ | |||
+ | Copy the '' | ||
You can use the tools provided by ElasticSearch to create the index or simply run the provided command line tool to do so: | You can use the tools provided by ElasticSearch to create the index or simply run the provided command line tool to do so: | ||
Line 59: | Line 66: | ||
The name of the index is determined by the configuration. | The name of the index is determined by the configuration. | ||
- | ==== Languages and fuzzy search ==== | + | === Re-creating the index === |
- | One of the main reasons for using a dedicated search engine is that it provides advanced features, such as fuzzy search. To enable it, the pages must be indexed using a linguistic analyzer in the appropriate language. Make sure to create the language mapping using the CLI tool **before** filling the index. | + | Sometimes it is necessary to throw away the old index and replace it with a new one. This can be done via the same DokuWiki script with an additional parameter: |
< | < | ||
- | ./ | + | ./ |
</ | </ | ||
- | If you have configured multiple languages using the [[plugin:translation|Translation | + | :!: Make sure to re-create your index after upgrading the plugin |
- | At present there is no special filter | + | ==== Languages and fuzzy search ==== |
+ | |||
+ | One of the main reasons for using a dedicated search engine | ||
+ | |||
+ | If you have configured multiple languages using the [[plugin: | ||
+ | |||
+ | By default all available translation are searched. Users can change the language selection | ||
+ | |||
+ | You can also enable translation detection in the plugin configuration. The option is called '' | ||
==== Index management ==== | ==== Index management ==== | ||
Line 80: | Line 95: | ||
./ | ./ | ||
</ | </ | ||
+ | |||
+ | You can index pages or media separately: | ||
+ | |||
+ | < | ||
+ | ./ | ||
+ | ./ | ||
+ | </ | ||
+ | |||
+ | |||
+ | ===== Other plugins ===== | ||
+ | |||
+ | The [[plugin: | ||
===== Development ===== | ===== Development ===== | ||
+ | |||
+ | ==== Plugin integration ==== | ||
+ | |||
+ | Elasticsearch emits several events that can be used by other plugins to put their own data into the search index. Take a look at the implementation [[plugin: | ||
+ | |||
+ | * '' | ||
+ | * '' | ||
+ | * '' | ||
+ | * '' | ||
+ | * '' | ||
==== Commit-Ticker ==== | ==== Commit-Ticker ==== | ||
Line 94: | Line 131: | ||
* search a specific language | * search a specific language | ||
* exact match (non-fuzzy search) | * exact match (non-fuzzy search) | ||
- | * integration of the [[plugin: | ||
- | |||
plugin/elasticsearch.1570844573.txt.gz · Last modified: 2019-10-12 03:42 by StarArmy