Package org.graylog2.indexer
Interface IndexSetRegistry
- All Known Implementing Classes:
MongoIndexSetRegistry
-
Method Summary
Modifier and TypeMethodDescriptionReturns theIndexSetfor the given ID.getAll()Returns a list of allIndexSetinstances.Returns theIndexSetthat is marked as default.getForIndex(String index) Returns theIndexSetfor the given index.getForIndices(Collection<String> indices) Returns theIndexSets for the given indices.String[]Returns the list of all index wildcards.String[]Returns a list of all managed indices.String[]Returns the list of all write index aliases.booleanisCurrentWriteIndex(String index) Checks if the given index is a current write index in anyIndexSet.booleanisCurrentWriteIndexAlias(String indexName) Checks if the given index name is a current write index alias in anyIndexSet.booleanisManagedIndex(String index) Checks if the given index is managed by any index set.isManagedIndex(Collection<String> indices) Checks if the given indices are managed by any index set.booleanisUp()Checks if all deflector aliases exist.Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
Method Details
-
getAll
Returns a list of allIndexSetinstances.- Returns:
- list of index sets
-
get
Returns theIndexSetfor the given ID.- Parameters:
indexSetId- ID of the index set- Returns:
- index set
-
getForIndex
Returns theIndexSetfor the given index.- Parameters:
index- name of the index- Returns:
- index set that manages the given index
-
getForIndices
Returns theIndexSets for the given indices.- Parameters:
indices- Collection with the name of the indicies- Returns:
- Set of index sets which manages the given indices
-
getDefault
IndexSet getDefault()Returns theIndexSetthat is marked as default. Throws anIllegalStateExceptionif the default index set does not exist.- Returns:
- the default index set
-
getManagedIndices
String[] getManagedIndices()Returns a list of all managed indices.- Returns:
- list of managed indices
-
isManagedIndex
Checks if the given index is managed by any index set.- Parameters:
index- the index name to check- Returns:
- true when index is managed by any index set, false otherwise
-
isManagedIndex
Checks if the given indices are managed by any index set.- Parameters:
indices- the index names to check- Returns:
- true when index is managed by any index set, false otherwise
-
getIndexWildcards
String[] getIndexWildcards()Returns the list of all index wildcards.- Returns:
- list of wildcards
-
getWriteIndexAliases
String[] getWriteIndexAliases()Returns the list of all write index aliases.- Returns:
- list of names
-
isUp
boolean isUp()Checks if all deflector aliases exist.- Returns:
- if all aliases exist
-
isCurrentWriteIndexAlias
Checks if the given index name is a current write index alias in anyIndexSet.- Parameters:
indexName- the name of the index to check- Returns:
- true when given index name is a current write index, false otherwise
-
isCurrentWriteIndex
Checks if the given index is a current write index in anyIndexSet.- Parameters:
index- the index name to check- Returns:
- true when index is a current write index, false otherwise
- Throws:
TooManyAliasesException
-