public class DefaultElasticsearchSchemaCreator extends Object implements ElasticsearchSchemaCreator
ElasticsearchSchemaCreator implementation.| Constructor and Description |
|---|
DefaultElasticsearchSchemaCreator(ElasticsearchSchemaAccessor schemaAccessor) |
| Modifier and Type | Method and Description |
|---|---|
void |
checkIndexExists(String indexName,
ExecutionOptions executionOptions)
Checks that an index already exists.
|
void |
createIndex(IndexMetadata indexMetadata,
ExecutionOptions executionOptions)
Create an index.
|
boolean |
createIndexIfAbsent(IndexMetadata indexMetadata,
ExecutionOptions executionOptions)
Create an index, but only if the index doesn't already exist.
|
void |
createMappings(IndexMetadata indexMetadata,
ExecutionOptions executionOptions)
Create mappings on a supposedly existing index.
|
public DefaultElasticsearchSchemaCreator(ElasticsearchSchemaAccessor schemaAccessor)
public void createIndex(IndexMetadata indexMetadata, ExecutionOptions executionOptions)
ElasticsearchSchemaCreatorcreateIndex in interface ElasticsearchSchemaCreatorindexMetadata - The expected index metadata.executionOptions - The execution options, giving more context information.public boolean createIndexIfAbsent(IndexMetadata indexMetadata, ExecutionOptions executionOptions)
ElasticsearchSchemaCreatorcreateIndexIfAbsent in interface ElasticsearchSchemaCreatorindexMetadata - The expected index metadata.executionOptions - The execution options, giving more context information.true if the index had to be created, false otherwise.public void checkIndexExists(String indexName, ExecutionOptions executionOptions)
ElasticsearchSchemaCreatorcheckIndexExists in interface ElasticsearchSchemaCreatorindexName - The expected index name.executionOptions - The execution options, giving more context information.public void createMappings(IndexMetadata indexMetadata, ExecutionOptions executionOptions)
ElasticsearchSchemaCreatorMappings are supposed to be absent from the index.
createMappings in interface ElasticsearchSchemaCreatorindexMetadata - The expected index metadata.executionOptions - The execution options, giving more context information.Copyright © 2006–2017 Hibernate. All rights reserved.