Class BaseFlightReader

java.lang.Object
org.apache.arrow.vector.ipc.ArrowReader
org.apache.arrow.adbc.driver.flightsql.BaseFlightReader
All Implemented Interfaces:
AutoCloseable, org.apache.arrow.vector.dictionary.DictionaryProvider
Direct Known Subclasses:
FlightInfoReader

public abstract class BaseFlightReader extends org.apache.arrow.vector.ipc.ArrowReader
Base class for ArrowReaders based on consuming data from FlightEndpoints.
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.apache.arrow.vector.dictionary.DictionaryProvider

    org.apache.arrow.vector.dictionary.DictionaryProvider.MapDictionaryProvider
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     
    protected final com.github.benmanes.caffeine.cache.LoadingCache<org.apache.arrow.flight.Location,FlightSqlClientWithCallOptions>
     

    Fields inherited from class org.apache.arrow.vector.ipc.ArrowReader

    allocator, dictionaries
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    BaseFlightReader(org.apache.arrow.memory.BufferAllocator allocator, FlightSqlClientWithCallOptions client, com.github.benmanes.caffeine.cache.LoadingCache<org.apache.arrow.flight.Location,FlightSqlClientWithCallOptions> clientCache, Supplier<List<org.apache.arrow.flight.FlightEndpoint>> rpcCall)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    addBytesRead(long bytes)
     
    long
     
    protected void
     
    boolean
     
    protected void
    loadRoot(org.apache.arrow.vector.VectorSchemaRoot root)
     
    protected void
     
    protected abstract void
    processRootFromStream(org.apache.arrow.vector.VectorSchemaRoot root)
     
    protected org.apache.arrow.vector.types.pojo.Schema
     

    Methods inherited from class org.apache.arrow.vector.ipc.ArrowReader

    close, close, ensureInitialized, getDictionaryIds, getDictionaryVectors, getVectorSchemaRoot, initialize, loadDictionary, loadRecordBatch, lookup, prepareLoadNextBatch

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

  • Method Details

    • loadNextBatch

      public boolean loadNextBatch() throws IOException
      Specified by:
      loadNextBatch in class org.apache.arrow.vector.ipc.ArrowReader
      Throws:
      IOException
    • readSchema

      protected org.apache.arrow.vector.types.pojo.Schema readSchema() throws IOException
      Specified by:
      readSchema in class org.apache.arrow.vector.ipc.ArrowReader
      Throws:
      IOException
    • bytesRead

      public long bytesRead()
      Specified by:
      bytesRead in class org.apache.arrow.vector.ipc.ArrowReader
    • closeReadSource

      protected void closeReadSource() throws IOException
      Specified by:
      closeReadSource in class org.apache.arrow.vector.ipc.ArrowReader
      Throws:
      IOException
    • processRootFromStream

      protected abstract void processRootFromStream(org.apache.arrow.vector.VectorSchemaRoot root)
    • addBytesRead

      protected void addBytesRead(long bytes)
    • populateEndpointData

      protected void populateEndpointData() throws AdbcException
      Throws:
      AdbcException
    • loadRoot

      protected void loadRoot(org.apache.arrow.vector.VectorSchemaRoot root)