Package org.apache.lucene.misc.store
Class ByteWritesTrackingDirectoryWrapper
java.lang.Object
org.apache.lucene.store.Directory
org.apache.lucene.store.FilterDirectory
org.apache.lucene.misc.store.ByteWritesTrackingDirectoryWrapper
- All Implemented Interfaces:
Closeable
,AutoCloseable
FilterDirectory
that tracks write amplification factor-
Field Summary
Fields inherited from class org.apache.lucene.store.FilterDirectory
in
-
Constructor Summary
ConstructorDescriptionByteWritesTrackingDirectoryWrapper
(Directory in, boolean trackTempOutput) Constructor with option to track tempOutput -
Method Summary
Modifier and TypeMethodDescriptioncreateOutput
(String name, IOContext ioContext) createTempOutput
(String prefix, String suffix, IOContext ioContext) long
long
Methods inherited from class org.apache.lucene.store.FilterDirectory
close, deleteFile, ensureOpen, fileLength, getDelegate, getPendingDeletions, listAll, obtainLock, openInput, rename, sync, syncMetaData, toString, unwrap
Methods inherited from class org.apache.lucene.store.Directory
copyFrom, getTempFileName, openChecksumInput
-
Field Details
-
trackTempOutput
public final boolean trackTempOutput
-
-
Constructor Details
-
ByteWritesTrackingDirectoryWrapper
-
ByteWritesTrackingDirectoryWrapper
Constructor with option to track tempOutput- Parameters:
in
- input DirectorytrackTempOutput
- if true, will also track temporary outputs created by this directory
-
-
Method Details
-
createOutput
- Overrides:
createOutput
in classFilterDirectory
- Throws:
IOException
-
createTempOutput
public IndexOutput createTempOutput(String prefix, String suffix, IOContext ioContext) throws IOException - Overrides:
createTempOutput
in classFilterDirectory
- Throws:
IOException
-
getFlushedBytes
public long getFlushedBytes() -
getMergedBytes
public long getMergedBytes()
-