org.elasticsearch.index.deletionpolicy
Class KeepLastNDeletionPolicy

java.lang.Object
  extended by org.elasticsearch.index.shard.AbstractIndexShardComponent
      extended by org.elasticsearch.index.deletionpolicy.KeepLastNDeletionPolicy
All Implemented Interfaces:
org.apache.lucene.index.IndexDeletionPolicy, IndexShardComponent

public class KeepLastNDeletionPolicy
extends AbstractIndexShardComponent
implements org.apache.lucene.index.IndexDeletionPolicy


Field Summary
 
Fields inherited from class org.elasticsearch.index.shard.AbstractIndexShardComponent
componentSettings, indexSettings, logger, shardId
 
Constructor Summary
KeepLastNDeletionPolicy(ShardId shardId, Settings indexSettings)
           
 
Method Summary
 void onCommit(List<? extends org.apache.lucene.index.IndexCommit> commits)
           
 void onInit(List<? extends org.apache.lucene.index.IndexCommit> commits)
           
 
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

KeepLastNDeletionPolicy

@Inject
public KeepLastNDeletionPolicy(ShardId shardId,
                                      @IndexSettings
                                      Settings indexSettings)
Method Detail

onInit

public void onInit(List<? extends org.apache.lucene.index.IndexCommit> commits)
            throws IOException
Specified by:
onInit in interface org.apache.lucene.index.IndexDeletionPolicy
Throws:
IOException

onCommit

public void onCommit(List<? extends org.apache.lucene.index.IndexCommit> commits)
              throws IOException
Specified by:
onCommit in interface org.apache.lucene.index.IndexDeletionPolicy
Throws:
IOException


Copyright © 2009-2012. All Rights Reserved.