-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
[HBASE-22476] FSDataInputStream is not closed. #263
Conversation
…ckup.impl.BackupManifest" FSDataInputStream is not close.
🎊 +1 overall
This message was automatically generated. |
@@ -438,6 +438,7 @@ public BackupManifest(FileSystem fs, Path backupPath) throws BackupException { | |||
long len = subFile.getLen(); | |||
byte[] pbBytes = new byte[(int) len]; | |||
in.readFully(pbBytes); | |||
in.close(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Better use the try-with-resources grammar?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh,yes, using the try-with-resources grammar is better. Thanks for reviewing the code.
…ckup.impl.BackupManifest" FSDataInputStream is not close.
🎊 +1 overall
This message was automatically generated. |
HBase-backup module's class "org.apache.hadoop.hbase.backup.impl.BackupManifest" FSDataInputStream is not close.