org.elasticsearch.index.store.support
Class AbstractIndexStore

java.lang.Object
  extended by org.elasticsearch.index.AbstractIndexComponent
      extended by org.elasticsearch.index.store.support.AbstractIndexStore
All Implemented Interfaces:
IndexComponent, IndexStore
Direct Known Subclasses:
ByteBufferIndexStore, FsIndexStore, RamIndexStore

public abstract class AbstractIndexStore
extends AbstractIndexComponent
implements IndexStore


Field Summary
protected  IndexService indexService
           
 
Fields inherited from class org.elasticsearch.index.AbstractIndexComponent
componentSettings, index, indexSettings, logger
 
Constructor Summary
protected AbstractIndexStore(Index index, Settings indexSettings, IndexService indexService)
           
 
Method Summary
 boolean canDeleteUnallocated(ShardId shardId)
          Returns true if this shard is allocated on this node.
 void deleteUnallocated(ShardId shardId)
          Deletes this shard store since its no longer allocated.
 
Methods inherited from class org.elasticsearch.index.AbstractIndexComponent
index, nodeName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.elasticsearch.index.store.IndexStore
backingStoreFreeSpace, backingStoreTotalSpace, persistent, shardStoreClass
 
Methods inherited from interface org.elasticsearch.index.IndexComponent
index
 

Field Detail

indexService

protected final IndexService indexService
Constructor Detail

AbstractIndexStore

protected AbstractIndexStore(Index index,
                             @IndexSettings
                             Settings indexSettings,
                             IndexService indexService)
Method Detail

canDeleteUnallocated

public boolean canDeleteUnallocated(ShardId shardId)
Description copied from interface: IndexStore
Returns true if this shard is allocated on this node. Allocated means that it has storage files that can be deleted using IndexStore.deleteUnallocated(org.elasticsearch.index.shard.ShardId).

Specified by:
canDeleteUnallocated in interface IndexStore

deleteUnallocated

public void deleteUnallocated(ShardId shardId)
                       throws java.io.IOException
Description copied from interface: IndexStore
Deletes this shard store since its no longer allocated.

Specified by:
deleteUnallocated in interface IndexStore
Throws:
java.io.IOException