Class MultiplePinotSegmentRecordReader

    • Constructor Detail

      • MultiplePinotSegmentRecordReader

        public MultiplePinotSegmentRecordReader​(List<File> indexDirs)
                                         throws Exception
        Read records using the passed in schema from multiple pinot segments.

        Passed in schema must be a subset of the segment schema.

        Parameters:
        indexDirs - a list of input segment directory paths
        Throws:
        Exception
      • MultiplePinotSegmentRecordReader

        public MultiplePinotSegmentRecordReader​(List<File> indexDirs,
                                                @Nullable
                                                Set<String> fieldsToRead,
                                                @Nullable
                                                List<String> sortOrder)
                                         throws Exception
        Read records using the passed in schema and in the order of sorted column from multiple pinot segments.

        Passed in schema must be a subset of the segment schema.

        If sort order is not specified, it will not attempt to sort the segments and simply concatenate the records from muiltiple segments.

        Parameters:
        indexDirs - a list of input paths for the segment indices
        fieldsToRead - if null or empty, reads all fields
        sortOrder - a list of column names that represent the sorting order
        Throws:
        Exception