|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.elasticsearch.index.shard.AbstractIndexShardComponent org.elasticsearch.index.deletionpolicy.SnapshotDeletionPolicy
public class SnapshotDeletionPolicy
Snapshot deletion policy allows to get snapshots of an index state (last commit or all commits) and if the deletion policy is used with all open index writers (JVM level) then the snapshot state will not be deleted until it will be released.
Field Summary |
---|
Fields inherited from class org.elasticsearch.index.shard.AbstractIndexShardComponent |
---|
componentSettings, indexSettings, logger, shardId |
Constructor Summary | |
---|---|
SnapshotDeletionPolicy(org.apache.lucene.index.IndexDeletionPolicy primary)
Constructs a new snapshot deletion policy that wraps the provided deletion policy. |
Method Summary | |
---|---|
void |
onCommit(List<? extends org.apache.lucene.index.IndexCommit> commits)
Called by Lucene.. |
void |
onInit(List<? extends org.apache.lucene.index.IndexCommit> commits)
Called by Lucene. |
SnapshotIndexCommit |
snapshot()
Returns a snapshot of the index (for the last commit point). |
SnapshotIndexCommits |
snapshots()
Snapshots all the current commits in the index. |
Methods inherited from class org.elasticsearch.index.shard.AbstractIndexShardComponent |
---|
indexSettings, managementGroupName, nodeName, shardId |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
@Inject public SnapshotDeletionPolicy(org.apache.lucene.index.IndexDeletionPolicy primary)
Method Detail |
---|
public void onInit(List<? extends org.apache.lucene.index.IndexCommit> commits) throws IOException
onCommit(java.util.List)
.
onInit
in interface org.apache.lucene.index.IndexDeletionPolicy
IOException
public void onCommit(List<? extends org.apache.lucene.index.IndexCommit> commits) throws IOException
SnapshotIndexCommit
and delegates to the wrapped deletion policy.
onCommit
in interface org.apache.lucene.index.IndexDeletionPolicy
IOException
public SnapshotIndexCommits snapshots() throws IOException
SnapshotIndexCommits.release()
to release it.
IOException
public SnapshotIndexCommit snapshot() throws IOException
SnapshotIndexCommit.release()
in order to release it.
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |