public class IndexPartition extends Object implements Closeable
Directory
, writer
and
SearcherManager
.Constructor and Description |
---|
IndexPartition(File partitionFolder,
org.apache.lucene.store.Directory directory,
org.apache.lucene.index.IndexWriterConfig writerConfig) |
Modifier and Type | Method and Description |
---|---|
PartitionSearcher |
acquireSearcher()
Return searcher for requested partition.
|
void |
close() |
org.apache.lucene.store.Directory |
getDirectory() |
org.apache.lucene.index.IndexWriter |
getIndexWriter() |
void |
maybeRefreshBlocking()
Refresh partition to make newly inserted data visible for readers.
|
org.neo4j.graphdb.ResourceIterator<File> |
snapshot()
Retrieve list of consistent Lucene index files for this partition.
|
public IndexPartition(File partitionFolder, org.apache.lucene.store.Directory directory, org.apache.lucene.index.IndexWriterConfig writerConfig) throws IOException
IOException
public org.apache.lucene.index.IndexWriter getIndexWriter()
public org.apache.lucene.store.Directory getDirectory()
public PartitionSearcher acquireSearcher() throws IOException
IOException
- if exception happened during searcher acquisitionpublic void maybeRefreshBlocking() throws IOException
IOException
- if refreshing fails.public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
public org.neo4j.graphdb.ResourceIterator<File> snapshot() throws IOException
IOException
- if any IO operation fails.Copyright © 2002–2016 The Neo4j Graph Database Project. All rights reserved.