java.lang.Object
org.elasticsearch.index.CloseUtils
Utilities to help with closing shards and indices
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Executor
Utility shard-close executor for the cases where we close anIndexService
without having created any shards, so we can assert that it's never used. -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Execute a naturally-async action (e.g.
-
Field Details
-
NO_SHARDS_CREATED_EXECUTOR
Utility shard-close executor for the cases where we close anIndexService
without having created any shards, so we can assert that it's never used.
-
-
Method Details
-
executeDirectly
public static void executeDirectly(CheckedConsumer<ActionListener<Void>, IOException> action) throws IOExceptionExecute a naturally-async action (e.g. to close a shard) but using the current thread so that it completes synchronously, re-throwing any exception that might be passed to its listener.- Throws:
IOException
-