-
Notifications
You must be signed in to change notification settings - Fork 9.1k
HADOOP-16637. Fix findbugs warnings in hadoop-cos. #1640
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
Conversation
💔 -1 overall
This message was automatically generated. |
@@ -249,7 +250,15 @@ public void storeEmptyFile(String key) throws IOException { | |||
|
|||
public PartETag uploadPart(File file, String key, String uploadId, | |||
int partNum) throws IOException { | |||
InputStream inputStream = new FileInputStream(file); | |||
InputStream inputStream = null; |
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.
looks broken, as L262 will always get a closed stream
Most of the changes look good; that input stream cleanup looks like it will break the code as a closed stream will always get passed along to the next method. The findbugs file probably just needs changing. Which endpoint did you run the tests against? |
We just ran the findbugs for the file. |
ok. You need to run the full test suite against a live service and declare which location/endpoint you tested with that's the policy for all object store patches I'm afraid -Yetus can't be given the credentials and yet we need to stop regressions creeping in. Sorry |
Thanks @steveloughran for the comment. |
} else { | ||
throw new IOException("creating buffer dir: " + dir.getAbsolutePath() | ||
+ "unsuccessfully."); | ||
} |
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.
Would you fix indent?
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.
Thanks @aajisaka for the review.
Yes I would fix it, and run the test on this issue.
Hi @cxorm, how is this issue going? |
Thanks @aajisaka for the review. |
💔 -1 overall
This message was automatically generated. |
Hi @cxorm there is still 1 findbugs warning, would you check this? Sorry for the late response. |
NOTICE
Please create an issue in ASF JIRA before opening a pull request,
and you need to set the title of the pull request which starts with
the corresponding JIRA issue number. (e.g. HADOOP-XXXXX. Fix a typo in YYY.)
For more details, please see https://cwiki.apache.org/confluence/display/HADOOP/How+To+Contribute