Close iter when reset to avoid resource not closed issue (#9035)

Signed-off-by: CH Kang <ch1010.developer@gmail.com>
master
ch1010 2020-07-25 19:31:26 +08:00 committed by GitHub
parent f33b08e20f
commit 5ff8d28b89
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -173,6 +173,7 @@ public class LineRecordReader extends BaseRecordReader {
throw new UnsupportedOperationException("Cannot reset without first initializing");
try {
inputSplit.reset();
close();
initialize(inputSplit);
splitIndex = 0;
} catch (Exception e) {