Class ElasticsearchIndexSettingsProvider
java.lang.Object
io.jmix.searchelasticsearch.index.ElasticsearchIndexSettingsProvider
@Component("search_ElasticsearchIndexSettingsProvider")
public class ElasticsearchIndexSettingsProvider
extends Object
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classIndex settings of one metadata generation: the context configured by the configurers and the settings computed from it, cached by entity class. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final co.elastic.clients.elasticsearch.ElasticsearchClientprotected final List<ElasticsearchIndexSettingsConfigurer> protected MetadataGenerationManagerprotected final com.fasterxml.jackson.databind.ObjectMapperprotected final GenerationStateStore<ElasticsearchIndexSettingsProvider.State> protected final List<ElasticsearchIndexSettingsConfigurer> -
Constructor Summary
ConstructorsConstructorDescriptionElasticsearchIndexSettingsProvider(List<ElasticsearchIndexSettingsConfigurer> configurers, co.elastic.clients.elasticsearch.ElasticsearchClient client) -
Method Summary
Modifier and TypeMethodDescriptionprotected co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysiscopyAnalysisSettings(co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysis source) protected co.elastic.clients.elasticsearch.indices.IndexSettingscopyIndexSettings(co.elastic.clients.elasticsearch.indices.IndexSettings source) protected co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysisdeserializeAnalysisSettings(String serializedSettings) protected co.elastic.clients.elasticsearch.indices.IndexSettingsdeserializeIndexSettings(String serializedSettings) co.elastic.clients.elasticsearch.indices.IndexSettingsgetSettingsForIndex(IndexConfiguration indexConfiguration) protected ElasticsearchIndexSettingsProvider.StategetState()Returns the settings state of the metadata generation pinned or current for the calling thread.protected booleanisEmptyAnalysisSettings(co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysis settings) protected booleanisEmptySettings(co.elastic.clients.elasticsearch.indices.IndexSettings settings) protected booleanisNewApiUsed(Class<?> entityClass) voidRemoves index settings cached for a retired metadata generation.protected voidprepareConfigurers(List<ElasticsearchIndexSettingsConfigurer> configurers) protected StringserializeJsonpSerializable(co.elastic.clients.json.JsonpSerializable object) protected com.fasterxml.jackson.databind.JsonNodetoJsonNode(co.elastic.clients.json.JsonpSerializable object) protected com.fasterxml.jackson.databind.node.ObjectNodetoObjectNode(co.elastic.clients.json.JsonpSerializable object)
-
Field Details
-
client
protected final co.elastic.clients.elasticsearch.ElasticsearchClient client -
customConfigurers
-
systemConfigurers
-
stateStore
-
objectMapper
protected final com.fasterxml.jackson.databind.ObjectMapper objectMapper -
metadataGenerationManager
-
-
Constructor Details
-
ElasticsearchIndexSettingsProvider
@Autowired public ElasticsearchIndexSettingsProvider(List<ElasticsearchIndexSettingsConfigurer> configurers, co.elastic.clients.elasticsearch.ElasticsearchClient client)
-
-
Method Details
-
getSettingsForIndex
public co.elastic.clients.elasticsearch.indices.IndexSettings getSettingsForIndex(IndexConfiguration indexConfiguration) -
onMetadataGenerationRetired
Removes index settings cached for a retired metadata generation.- Parameters:
event- retired-generation event
-
getState
Returns the settings state of the metadata generation pinned or current for the calling thread. The configurers are run once per generation, so they see the index configurations and entity classes of that generation. -
configureContext
-
prepareConfigurers
-
copyIndexSettings
protected co.elastic.clients.elasticsearch.indices.IndexSettings copyIndexSettings(co.elastic.clients.elasticsearch.indices.IndexSettings source) -
copyAnalysisSettings
protected co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysis copyAnalysisSettings(co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysis source) -
serializeJsonpSerializable
-
deserializeIndexSettings
protected co.elastic.clients.elasticsearch.indices.IndexSettings deserializeIndexSettings(String serializedSettings) -
deserializeAnalysisSettings
protected co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysis deserializeAnalysisSettings(String serializedSettings) -
toJsonNode
protected com.fasterxml.jackson.databind.JsonNode toJsonNode(co.elastic.clients.json.JsonpSerializable object) -
toObjectNode
protected com.fasterxml.jackson.databind.node.ObjectNode toObjectNode(co.elastic.clients.json.JsonpSerializable object) -
isNewApiUsed
-
isEmptySettings
protected boolean isEmptySettings(co.elastic.clients.elasticsearch.indices.IndexSettings settings) -
isEmptyAnalysisSettings
protected boolean isEmptyAnalysisSettings(co.elastic.clients.elasticsearch.indices.IndexSettingsAnalysis settings)
-