HDFS-15908. Possible Resource Leak in org.apache.hadoop.hdfs.qjournal.server.Journal (#2790). Contributed by Narges Shadab.

Signed-off-by: Ayush Saxena <ayushsaxena@apache.org>
(cherry picked from commit d77c7ab4e0)
This commit is contained in:
Narges Shadab 2021-03-23 04:36:58 -07:00 committed by Wei-Chiu Chuang
parent a216ee3b85
commit 4abe6e6ac1
1 changed files with 1 additions and 1 deletions

View File

@ -264,9 +264,9 @@ public class Journal implements Closeable {
*/
@Override // Closeable
public void close() throws IOException {
storage.close();
IOUtils.closeStream(committedTxnId);
IOUtils.closeStream(curSegment);
storage.close();
}
JNStorage getStorage() {