IndexEventListener
public class SyncedFlushService extends AbstractComponent implements IndexEventListener
Modifier and Type | Class | Description |
---|---|---|
static class |
SyncedFlushService.InFlightOpsRequest |
|
static class |
SyncedFlushService.PreShardSyncedFlushRequest |
|
static class |
SyncedFlushService.ShardSyncedFlushRequest |
|
static class |
SyncedFlushService.ShardSyncedFlushResponse |
Response for third step of synced flush (writing the sync id) for one shard copy
|
deprecationLogger, logger, settings
Constructor | Description |
---|---|
SyncedFlushService(Settings settings,
IndicesService indicesService,
ClusterService clusterService,
TransportService transportService,
IndexNameExpressionResolver indexNameExpressionResolver) |
Modifier and Type | Method | Description |
---|---|---|
void |
attemptSyncedFlush(java.lang.String[] aliasesOrIndices,
IndicesOptions indicesOptions,
ActionListener<SyncedFlushResponse> listener) |
a utility method to perform a synced flush for all shards of multiple indices.
|
void |
attemptSyncedFlush(ShardId shardId,
ActionListener<ShardsSyncedFlushResult> actionListener) |
|
protected void |
getInflightOpsCount(ShardId shardId,
ClusterState state,
IndexShardRoutingTable shardRoutingTable,
ActionListener<org.elasticsearch.indices.flush.SyncedFlushService.InFlightOpsResponse> listener) |
returns the number of in flight operations on primary.
|
void |
onShardInactive(IndexShard indexShard) |
Called when a shard is marked as inactive
|
logDeprecatedSetting, logRemovedSetting, nodeName
afterIndexCreated, afterIndexRemoved, afterIndexShardClosed, afterIndexShardCreated, afterIndexShardDeleted, afterIndexShardStarted, beforeIndexAddedToCluster, beforeIndexCreated, beforeIndexRemoved, beforeIndexShardClosed, beforeIndexShardCreated, beforeIndexShardDeleted, indexShardStateChanged, onStoreClosed, shardRoutingChanged
@Inject public SyncedFlushService(Settings settings, IndicesService indicesService, ClusterService clusterService, TransportService transportService, IndexNameExpressionResolver indexNameExpressionResolver)
public void onShardInactive(IndexShard indexShard)
IndexEventListener
onShardInactive
in interface IndexEventListener
indexShard
- The shard that was marked inactivepublic void attemptSyncedFlush(java.lang.String[] aliasesOrIndices, IndicesOptions indicesOptions, ActionListener<SyncedFlushResponse> listener)
attemptSyncedFlush(ShardId, ActionListener)
for more details.public void attemptSyncedFlush(ShardId shardId, ActionListener<ShardsSyncedFlushResult> actionListener)
protected void getInflightOpsCount(ShardId shardId, ClusterState state, IndexShardRoutingTable shardRoutingTable, ActionListener<org.elasticsearch.indices.flush.SyncedFlushService.InFlightOpsResponse> listener)