Interface TableMetadataProvider

All Known Subinterfaces:
ParquetMetadataProvider, ParquetTableMetadataProvider
All Known Implementing Classes:
BaseParquetMetadataProvider, DeltaParquetTableMetadataProvider, HiveParquetTableMetadataProvider, MetastoreFileTableMetadataProvider, MetastoreParquetTableMetadataProvider, ParquetTableMetadataProviderImpl, SimpleFileTableMetadataProvider

public interface TableMetadataProvider
Base interface for providing table, partition, file etc. metadata for specific table. getPartitionsMetadata(), getFilesMetadata() and other methods which return collections return empty collection instead of null for the case when required metadata level is not available, or cannot re obtained using current TableMetadataProvider instance.
  • Method Details

    • getTableMetadata

      TableMetadata getTableMetadata()
      Returns TableMetadata instance which provides metadata for table and columns metadata.
      Returns:
      TableMetadata instance
    • getPartitionColumns

      List<SchemaPath> getPartitionColumns()
      Returns list of partition columns for table from this TableMetadataProvider.
      Returns:
      list of partition columns
    • getPartitionsMetadata

      List<PartitionMetadata> getPartitionsMetadata()
      Returns list of PartitionMetadata instances which provides metadata for specific partitions and its columns.
      Returns:
      list of PartitionMetadata instances
    • getPartitionMetadata

      List<PartitionMetadata> getPartitionMetadata(SchemaPath columnName)
      Returns list of PartitionMetadata instances which corresponds to partitions for specified column and provides metadata for specific partitions and its columns.
      Returns:
      list of PartitionMetadata instances which corresponds to partitions for specified column
    • getFilesMetadataMap

      Map<org.apache.hadoop.fs.Path,FileMetadata> getFilesMetadataMap()
      Returns map of FileMetadata instances which provides metadata for specific file and its columns.
      Returns:
      map of FileMetadata instances
    • getSegmentsMetadataMap

      Map<org.apache.hadoop.fs.Path,SegmentMetadata> getSegmentsMetadataMap()
      Returns map of SegmentMetadata instances which provides metadata for segment and its columns.
      Returns:
      map of SegmentMetadata instances
    • getFileMetadata

      FileMetadata getFileMetadata(org.apache.hadoop.fs.Path location)
      Returns FileMetadata instance which corresponds to metadata of file for specified location.
      Parameters:
      location - location of the file
      Returns:
      FileMetadata instance which corresponds to metadata of file for specified location
    • getFilesForPartition

      List<FileMetadata> getFilesForPartition(PartitionMetadata partition)
      Returns list of FileMetadata instances which belongs to specified partitions.
      Parameters:
      partition - partition which
      Returns:
      list of FileMetadata instances which belongs to specified partitions
    • getNonInterestingColumnsMetadata

      NonInterestingColumnsMetadata getNonInterestingColumnsMetadata()
      Returns NonInterestingColumnsMetadata instance which provides metadata for non-interesting columns.
      Returns:
      NonInterestingColumnsMetadata instance
    • checkMetadataVersion

      boolean checkMetadataVersion()
      Whether metadata actuality should be checked.
      Returns:
      true if metadata actuality should be checked