You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Sergey Shelukhin (JIRA)" <ji...@apache.org> on 2016/03/08 00:05:40 UTC
[jira] [Assigned] (HIVE-13216) ORC Reader will leave file open
until GC when opening a malformed ORC file
[ https://issues.apache.org/jira/browse/HIVE-13216?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Sergey Shelukhin reassigned HIVE-13216:
---------------------------------------
Assignee: Sergey Shelukhin
> ORC Reader will leave file open until GC when opening a malformed ORC file
> --------------------------------------------------------------------------
>
> Key: HIVE-13216
> URL: https://issues.apache.org/jira/browse/HIVE-13216
> Project: Hive
> Issue Type: Bug
> Components: File Formats, ORC
> Affects Versions: 1.2.0, 1.2.1
> Reporter: Yuxing Yao
> Assignee: Sergey Shelukhin
> Priority: Minor
>
> In ORC extractMetaInfoFromFooter method of ReaderImpl.java:
> A new input stream is open without try-catch-finally to enforce closing.
> Once the footer parse has some exception, the stream close will miss.
> Until GC happen to close the stream.
> private static FileMetaInfo extractMetaInfoFromFooter(FileSystem fs,
> Path path,
> long maxFileLength
> ) throws IOException {
> FSDataInputStream file = fs.open(path);
> ...
> file.close();
> return new FileMetaInfo(
> ps.getCompression().toString(),
> (int) ps.getCompressionBlockSize(),
> (int) ps.getMetadataLength(),
> buffer,
> ps.getVersionList(),
> writerVersion
> );
> }
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)