PLT-6472: Basic Elastic Search implementation. (#6382)
* PLT-6472: Basic Elastic Search implementation. This currently supports indexing of posts at create/update/delete time. It does not support batch indexing or reindexing, and does not support any entities other than posts yet. The purpose is to more-or-less replicate the existing full-text search feature but with some of the immediate benefits of using elastic search. * Alter settings for AWS compatability. * Remove unneeded i18n strings.
Этот коммит содержится в:
коммит произвёл
Harrison Healey
родитель
2bbedd9def
Коммит
0db5e3922f
@@ -492,6 +492,11 @@ func getClientConfig(c *model.Config) map[string]string {
|
||||
props["PasswordRequireNumber"] = strconv.FormatBool(*c.PasswordSettings.Number)
|
||||
props["PasswordRequireSymbol"] = strconv.FormatBool(*c.PasswordSettings.Symbol)
|
||||
}
|
||||
|
||||
if *License.Features.ElasticSearch {
|
||||
props["ElasticSearchEnableIndexing"] = strconv.FormatBool(*c.ElasticSearchSettings.EnableIndexing)
|
||||
props["ElasticSearchEnableSearching"] = strconv.FormatBool(*c.ElasticSearchSettings.EnableSearching)
|
||||
}
|
||||
}
|
||||
|
||||
return props
|
||||
@@ -560,6 +565,16 @@ func Desanitize(cfg *model.Config) {
|
||||
cfg.SqlSettings.AtRestEncryptKey = Cfg.SqlSettings.AtRestEncryptKey
|
||||
}
|
||||
|
||||
if *cfg.ElasticSearchSettings.ConnectionUrl == model.FAKE_SETTING {
|
||||
*cfg.ElasticSearchSettings.ConnectionUrl = *Cfg.ElasticSearchSettings.ConnectionUrl
|
||||
}
|
||||
if *cfg.ElasticSearchSettings.Username == model.FAKE_SETTING {
|
||||
*cfg.ElasticSearchSettings.Username = *Cfg.ElasticSearchSettings.Username
|
||||
}
|
||||
if *cfg.ElasticSearchSettings.Password == model.FAKE_SETTING {
|
||||
*cfg.ElasticSearchSettings.Password = *Cfg.ElasticSearchSettings.Password
|
||||
}
|
||||
|
||||
for i := range cfg.SqlSettings.DataSourceReplicas {
|
||||
cfg.SqlSettings.DataSourceReplicas[i] = Cfg.SqlSettings.DataSourceReplicas[i]
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user