Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ORC-419: Ensure to call close at RecordReaderImpl constructor exception #325

Merged
merged 1 commit into from Oct 17, 2018
Merged

ORC-419: Ensure to call close at RecordReaderImpl constructor exception #325

merged 1 commit into from Oct 17, 2018

Conversation

dongjoon-hyun
Copy link
Member

Currently, there is no way to call RecordReaderImpl.close if RecordReader.rows fails at creating RecordReaderImpl. This PR aims to try to invoke close in the constructor in case of Exceptions.

  @Override
  public RecordReader rows(Options options) throws IOException {
    LOG.info("Reading ORC rows from " + path + " with " + options);
    return new RecordReaderImpl(this, options);
  }

@prasanthj prasanthj merged commit cc7810e into apache:master Oct 17, 2018
@dongjoon-hyun
Copy link
Member Author

Thank you so much!

@dongjoon-hyun dongjoon-hyun deleted the ORC-413-3 branch October 17, 2018 23:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants