Affects Version/s: 7.3.X, Master
Component/s: Search Infrastructure > Elasticsearch Connector
There are several languages in Liferay (et_EE, fa_IR, gl_ES, in_ID, lt_LT) with an available analyzer bundled in the Elasticsearch server, that are missing in the liferay-type-mappings.json Elasticsearch mapping configuration file.
We should configure all the languages with a available analyzer
Steps to reproduce
- Go to Control Panel => Instance Settings => Localization
- Add following languages to the Liferay instance
- Estonian (et_EE)
- Persian (fa_IR)
- Galician (gl_ES)
- Indonesian (in_ID)
- Lithuanian (lt_LT)
- Go to Control panel => Search
- Go to the "Index Actions" and Execute a full reindex
- Once the full reindex ends, go to the "Field Mappings"
- Open the field mappings of index "liferay-0"
- Copy the mappings to a text editor and check the "description_<languageId>" field of the problematic languages:
- : the mapping contains a "analyzer" child node with the correct language analyzer
- : the mapping doesn't contain a "analyzer", it only contains the "store" and "type" children nodes
Note: there are some languages in Liferay without an available analyzer in the Elasticsearch side, they are: Croatian (hr_HR), Hebrew (iw_IL), Kazakh (kk_KZ), Lao (lo_LA), Malay (ms_MY), Slovak (sk_SK), Slovenian (sl_SI), Serbian (sr_RS), Tamil (ta_IN), Ukrainian (uk_UA), Vietnamese (vi_VN).
These languages are analyzed using the standard analyzer. As a workaround, you can always create a custom analyzer in Elasticsearch and apply them in the Liferay configuration.
The fix requires to perform a full reindex through the Search admin.