Package org.graylog2.indexer.indices
Interface IndicesAdapter
public interface IndicesAdapter
-
Method Summary
Modifier and TypeMethodDescriptionboolean
aliasExists
(String alias) void
closedIndices
(Collection<String> indices) void
create
(String indexName, IndexSettings indexSettings) void
cycleAlias
(String aliasName, String targetIndex) void
cycleAlias
(String aliasName, String targetIndex, String oldIndex) void
boolean
deleteIndexTemplate
(String templateName) boolean
ensureIndexTemplate
(String templateName, Map<String, Object> template) boolean
fieldsInIndices
(String[] writeIndexWildcards) void
getIndexId
(String index) getIndexStats
(String index) com.fasterxml.jackson.databind.JsonNode
getIndexStats
(Collection<String> index) getIndicesBlocksStatus
(List<String> indices) Optional<org.joda.time.DateTime>
indexCreationDate
(String index) indexRangeStatsOfIndex
(String index) boolean
indexTemplateExists
(String templateName) indicesStats
(Collection<String> indices) boolean
boolean
void
markIndexReopened
(String index) void
move
(String source, String target, Consumer<IndexMoveResult> resultCallback) long
numberOfMessages
(String indexName) void
void
optimizeIndex
(String index, int maxNumSegments, com.github.joschi.jadconfig.util.Duration timeout) void
removeAlias
(String indexName, String alias) void
removeAliases
(Set<String> indices, String alias) resolveAlias
(String alias) void
setReadOnly
(String index) storeSizeInBytes
(String index) void
Add fields to an existing index or to change search only settings of existing fieldswaitForRecovery
(String index) waitForRecovery
(String index, int timeout)
-
Method Details
-
move
-
delete
-
resolveAlias
-
create
-
updateIndexMapping
void updateIndexMapping(@Nonnull String indexName, @Nonnull String mappingType, @Nonnull Map<String, Object> mapping) Add fields to an existing index or to change search only settings of existing fields- Parameters:
indexName
- existing index namemappingType
- target mapping type (e.g. message). Not relevant for ES7+ (will be simply ignored).mapping
- field mappings
-
ensureIndexTemplate
-
indexTemplateExists
-
indexCreationDate
-
openIndex
-
setReadOnly
-
flush
-
markIndexReopened
-
removeAlias
-
close
-
numberOfMessages
-
aliasExists
- Throws:
IOException
-
aliases
-
deleteIndexTemplate
-
fieldsInIndices
-
closedIndices
-
indicesStats
-
getIndexStats
-
getIndexStats
-
getIndicesBlocksStatus
-
exists
- Throws:
IOException
-
indices
-
storeSizeInBytes
-
cycleAlias
-
cycleAlias
-
removeAliases
-
optimizeIndex
void optimizeIndex(String index, int maxNumSegments, com.github.joschi.jadconfig.util.Duration timeout) -
indexRangeStatsOfIndex
-
waitForRecovery
-
waitForRecovery
-
isOpen
-
isClosed
-
getIndexId
-