public class SnapshotShardsService extends AbstractLifecycleComponent<SnapshotShardsService> implements ClusterStateListener
| Modifier and Type | Class and Description |
|---|---|
static class |
SnapshotShardsService.UpdateIndexShardSnapshotStatusRequest
Internal request that is used to send changes in snapshot status to master
|
| Modifier and Type | Field and Description |
|---|---|
static String |
UPDATE_SNAPSHOT_ACTION_NAME |
lifecycledeprecationLogger, logger, settings| Constructor and Description |
|---|
SnapshotShardsService(Settings settings,
ClusterService clusterService,
SnapshotsService snapshotsService,
ThreadPool threadPool,
TransportService transportService,
IndicesService indicesService) |
| Modifier and Type | Method and Description |
|---|---|
void |
clusterChanged(ClusterChangedEvent event)
Called when cluster state changes.
|
Map<ShardId,IndexShardSnapshotStatus> |
currentSnapshotShards(SnapshotId snapshotId)
Returns status of shards that are snapshotted on the node and belong to the given snapshot
|
protected void |
doClose() |
protected void |
doStart() |
protected void |
doStop() |
void |
updateIndexShardSnapshotStatus(SnapshotId snapshotId,
ShardId shardId,
SnapshotsInProgress.ShardSnapshotStatus status)
Updates the shard status
|
addLifecycleListener, close, lifecycleState, removeLifecycleListener, start, stoplogDeprecatedSetting, logRemovedSetting, nodeNamepublic static final String UPDATE_SNAPSHOT_ACTION_NAME
@Inject public SnapshotShardsService(Settings settings, ClusterService clusterService, SnapshotsService snapshotsService, ThreadPool threadPool, TransportService transportService, IndicesService indicesService)
protected void doStart()
doStart in class AbstractLifecycleComponent<SnapshotShardsService>protected void doStop()
doStop in class AbstractLifecycleComponent<SnapshotShardsService>protected void doClose()
doClose in class AbstractLifecycleComponent<SnapshotShardsService>public void clusterChanged(ClusterChangedEvent event)
ClusterStateListenerclusterChanged in interface ClusterStateListenerpublic Map<ShardId,IndexShardSnapshotStatus> currentSnapshotShards(SnapshotId snapshotId)
This method is executed on data node
snapshotId - snapshot idpublic void updateIndexShardSnapshotStatus(SnapshotId snapshotId, ShardId shardId, SnapshotsInProgress.ShardSnapshotStatus status)
Copyright © 2009–2017. All rights reserved.