Class SchemaTreeProvider

java.lang.Object
org.apache.drill.exec.store.SchemaTreeProvider
All Implemented Interfaces:
AutoCloseable

public class SchemaTreeProvider extends Object implements AutoCloseable
Creates new schema trees. It keeps track of newly created schema trees and closes them safely as part of close().
  • Constructor Details

  • Method Details

    • createRootSchema

      public org.apache.calcite.schema.SchemaPlus createRootSchema(OptionManager options)
      Return root schema for process user.
      Parameters:
      options - list of options
      Returns:
      root of the schema tree
    • createRootSchema

      public org.apache.calcite.schema.SchemaPlus createRootSchema(String userName, SchemaConfig.SchemaConfigInfoProvider provider)
      Return root schema with schema owner as the given user.
      Parameters:
      userName - Name of the user who is accessing the storage sources.
      provider - SchemaConfig.SchemaConfigInfoProvider instance
      Returns:
      Root of the schema tree.
    • createRootSchema

      public org.apache.calcite.schema.SchemaPlus createRootSchema(SchemaConfig schemaConfig)
      Create and return a SchemaTree with given schemaConfig.
      Parameters:
      schemaConfig -
      Returns:
      Root of the schema tree.
    • close

      public void close() throws Exception
      Specified by:
      close in interface AutoCloseable
      Throws:
      Exception