Class SmbDirectoryWrapper

java.lang.Object
org.apache.lucene.store.Directory
org.apache.lucene.store.FilterDirectory
org.opensearch.index.store.SmbDirectoryWrapper
All Implemented Interfaces:
Closeable, AutoCloseable

public final class SmbDirectoryWrapper extends org.apache.lucene.store.FilterDirectory
This class is used to wrap an existing FSDirectory so that the new shard segment files will be opened for Read and Write access.

When storing index files on an SMB share like Azure File Service, opening the file for Read access can save a lot of roundtrips to the storage server and thus offering better performance.

  • Field Summary

    Fields inherited from class org.apache.lucene.store.FilterDirectory

    in
  • Constructor Summary

    Constructors
    Constructor
    Description
    SmbDirectoryWrapper(org.apache.lucene.store.FSDirectory in)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.apache.lucene.store.IndexOutput
    createOutput(String name, org.apache.lucene.store.IOContext context)
     
     

    Methods inherited from class org.apache.lucene.store.FilterDirectory

    close, createTempOutput, deleteFile, ensureOpen, fileLength, getDelegate, listAll, obtainLock, openInput, rename, sync, syncMetaData, toString, unwrap

    Methods inherited from class org.apache.lucene.store.Directory

    copyFrom, getTempFileName, openChecksumInput

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • SmbDirectoryWrapper

      public SmbDirectoryWrapper(org.apache.lucene.store.FSDirectory in)
  • Method Details

    • createOutput

      public org.apache.lucene.store.IndexOutput createOutput(String name, org.apache.lucene.store.IOContext context) throws IOException
      Overrides:
      createOutput in class org.apache.lucene.store.FilterDirectory
      Throws:
      IOException
    • getPendingDeletions

      public Set<String> getPendingDeletions() throws IOException
      Overrides:
      getPendingDeletions in class org.apache.lucene.store.FilterDirectory
      Throws:
      IOException