Class ReadYourWritesIndexAccessor
java.lang.Object
com.atlassian.jira.search.opensearch.consistency.ReadYourWritesIndexAccessor
- All Implemented Interfaces:
IndexAccessor,WritableIndexAccessor
Decorates a
WritableIndexAccessor to apply read-your-writes consistency- Since:
- 11.1
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns current schema of the index.Returns current searcher of the index.Get the writer of the index.voidrecreate()Deletes and recreates an empty indexvoidrefresh()Calling this method forces the data mutated so far to become available for search thus by passing the default visibility mode.voidupdateSchema(UnaryOperator<IndexSchema> schemaProvider) Updates the index.
-
Constructor Details
-
ReadYourWritesIndexAccessor
-
-
Method Details
-
getWriter
Description copied from interface:WritableIndexAccessorGet the writer of the index.- Specified by:
getWriterin interfaceWritableIndexAccessor- Returns:
- writer of the index.
-
getSchema
Description copied from interface:IndexAccessorReturns current schema of the index.- Specified by:
getSchemain interfaceIndexAccessor- Returns:
- schema of the index.
-
getSearcher
Description copied from interface:IndexAccessorReturns current searcher of the index.- Specified by:
getSearcherin interfaceIndexAccessor- Returns:
- searcher of the index.
-
refresh
Description copied from interface:IndexAccessorCalling this method forces the data mutated so far to become available for search thus by passing the default visibility mode.- Specified by:
refreshin interfaceIndexAccessor- Throws:
IndexOperationException- if the operation failed
-
recreate
Description copied from interface:IndexAccessorDeletes and recreates an empty index- Specified by:
recreatein interfaceIndexAccessor- Throws:
IndexOperationException- if the operation failed
-
updateSchema
Description copied from interface:IndexAccessorUpdates the index.- Specified by:
updateSchemain interfaceIndexAccessor- Parameters:
schemaProvider- a function that takes the current schema and returns the new schema- Throws:
IndexOperationException- if the operation failed
-