@Override
    public Reader<E> createReader(
            Configuration config, FSDataInputStream stream, long fileLen, long splitEnd)
            throws IOException {

        // current version does not support splitting.
        checkNotSplit(fileLen, splitEnd);

        return new AvroParquetRecordReader<E>(
                AvroParquetReader.<E>builder(new ParquetInputFile(stream, fileLen))
                        .withDataModel(getDataModel())
                        .withConf(HadoopUtils.getHadoopConfiguration(config))
                        .build());
    }
@Test
    void testCreateGenericReaderWithSplitting() {
        assertThatThrownBy(
                        () ->
                                createReader(
                                        AvroParquetReaders.forGenericRecord(schema),
                                        new Configuration(),
                                        userPath,
                                        5,
                                        5))
                .isInstanceOf(IllegalArgumentException.class);
    }