Details
Description
Currently, `RecordReaderImpl` invokes `dataReader.open` in the middle of the constructor. We can postpone this until `advanceToNextRow` reads the stripe at the end of the constructor.
this.dataReader.open();
This will reduce the chance of potential open-file leakages due to IOException and OOM during `RecordReaderImpl` construction. Also, we can avoid it completely when there is no stripe in the file.
Attachments
Issue Links
- is related to
-
SPARK-23390 Flaky test: FileBasedDataSourceSuite
- Resolved
-
SPARK-25688 Potential resource leak in ORC
- Resolved
- links to