Interface ParquetMetadataFileWriter

All Known Implementing Classes:
NullParquetMetadataFileWriter

public interface ParquetMetadataFileWriter
Used to write "_metadata" and "_common_metadata" files for Parquet.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addParquetFileMetadata(URI parquetFileURI, org.apache.parquet.hadoop.metadata.ParquetMetadata metadata)
    Add the parquet metadata for the provided parquet file to the list of metadata to be written to combined metadata files.
    void
    writeMetadataFiles(CompletableOutputStream metadataOutputStream, CompletableOutputStream commonMetadataOutputStream)
    Write the combined metadata to the provided streams and clear the metadata accumulated so far.
  • Method Details

    • addParquetFileMetadata

      void addParquetFileMetadata(URI parquetFileURI, org.apache.parquet.hadoop.metadata.ParquetMetadata metadata)
      Add the parquet metadata for the provided parquet file to the list of metadata to be written to combined metadata files.
      Parameters:
      parquetFileURI - The parquet file destination URI
      metadata - The parquet metadata corresponding to the parquet file
    • writeMetadataFiles

      void writeMetadataFiles(CompletableOutputStream metadataOutputStream, CompletableOutputStream commonMetadataOutputStream) throws IOException
      Write the combined metadata to the provided streams and clear the metadata accumulated so far. The output streams should be marked as CompletableOutputStream.done() after writing is finished.
      Parameters:
      metadataOutputStream - The output stream for the "_metadata" file
      commonMetadataOutputStream - The output stream for the "_common_metadata" file
      Throws:
      IOException